fixed issues and added register user to server