Fixed session and initialization bugs.
Merge branch 'login-rebase' of github.com:scrollback/scrollback into login-rebase