refactored registation and getAllUsers, confirmed login in functioning