fixed a small bug with Registering