Refactored login code, storing user data in session, better errors

Put login in a waterfall, now storing user information upon login (see #8), better error handling.
I'm not sure about caching an error before the waterfall. We loose the cause of the error that way