move loadCurrentUser function