fix(client): client disconnect beforeunload now triggers

refs #161