Improved login handling, missing logout