Moved updating user details functionality to model to follow best practice