add optional() method to Validator interface

This commit is contained in:
Sobit Akhmedov 2015-06-02 19:03:21 +02:00
parent 484544d14d
commit e8ac76dbcf

View File

@ -150,6 +150,10 @@ declare module ExpressValidator {
* Will work against Visa, MasterCard, American Express, Discover, Diners Club, and JCB card numbering formats
*/
isCreditCard(): Validator;
/**
* Check an input only when the input exists
*/
optional(): Validator;
}
interface Sanitizer {