Fixing bug where the lastLoginUri gets set to the wrong object