Fixed a bug involving leaving newly created sessions.

Before this fix, it was not possible to leave newly created sessions
without first refreshing the page to update the newly created session’s
id field on the client side.