Improvements on logged in user persistence