disable login and register if a validation error is present