Created
February 18, 2012 22:07
-
-
Save sgnix/1861129 to your computer and use it in GitHub Desktop.
Validate::Tiny 1
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
my %rules = ( | |
fields => [ 'name', 'email', 'pass' ], # What fields | |
filters => [ | |
name => sub { ... }, # Filter name | |
email => sub { ... }, # Filter email | |
pass => sub { ... } # Filter pass | |
], | |
checks => [ | |
name => sub { ... }, # Check if name is good | |
email => sub { ... }, # Check email | |
pass => sub { ... } # Check password | |
] | |
); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment