Fixed webpage not unattached correctly when app inactive in userspage. Added going back to firstpage automatically after log in happened