finishing the controller part of the validation