refactored user model, consolidated user updates and inserts into database into save function