login in and creating user work, also flashing messages