Created
August 5, 2018 23:02
-
-
Save Arrlindii/17c18494be783d122f576c997d0cb72e to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
extension UITextField { | |
func validatedText(validationType: ValidatorType) throws -> String { | |
let validator = VaildatorFactory.validatorFor(type: validationType) | |
return try validator.validated(self.text!) | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment