refactoring updateUserStatus