@@ -91,7 +91,7 @@ component accessors="true" serialize="false" implements="IValidationManager" sin
91
91
* @excludeFields.hint An optional list of fields to exclude from the validation.
92
92
* @IncludeFields.hint An optional list of fields to include in the validation.
93
93
*/
94
- IValidationResult function validate (required any target , string fields = " *" , any constraints = " " , string locale = " " , string excludeFields = " " , string includeFields = " " ){
94
+ IValidationResult function validate ( required any target , string fields = " *" , any constraints = " " , string locale = " " , string excludeFields = " " , string includeFields = " " ){
95
95
var targetName = " " ;
96
96
97
97
// Do we have a real object or a structure?
@@ -131,9 +131,9 @@ component accessors="true" serialize="false" implements="IValidationManager" sin
131
131
}
132
132
if ( validateField ){
133
133
// verify we can validate the field described in the constraint
134
- if ( arguments .fields == " *" || listFindNoCase (arguments .fields , this Field ) ) {
134
+ if ( arguments .fields == " *" || listFindNoCase ( arguments .fields , this Field ) ) {
135
135
// process the validation rules on the target field using the constraint validation data
136
- processRules (results = results , rules = allConstraints [this Field ], target = arguments .target , field = this Field , locale = arguments .locale );
136
+ processRules ( results = results , rules = allConstraints [ this Field ], target = arguments .target , field = this Field , locale = arguments .locale );
137
137
}
138
138
}
139
139
@@ -149,7 +149,7 @@ component accessors="true" serialize="false" implements="IValidationManager" sin
149
149
// process the incoming rules
150
150
for ( var key in arguments .rules ){
151
151
// if message validators, just ignore
152
- if ( reFindNoCase ( " ^(# replace ( variables . validValidators , " , " , " | " , " all " ) #) Message$" , key ) ){ continue ; }
152
+ if ( reFindNoCase ( " Message$" , key ) ){ continue ; }
153
153
// if not in list, ignore
154
154
if ( ! listFindNoCase ( variables .validValidators , key ) ){ continue ; }
155
155
@@ -190,6 +190,7 @@ component accessors="true" serialize="false" implements="IValidationManager" sin
190
190
return wirebox .getInstance ( arguments .validationData );
191
191
}
192
192
default : {
193
+ if ( wirebox .getBinder ().mappingExists ( validatorType ) ) { return wirebox .getInstance ( validatorType ); }
193
194
throw (message = " The validator you requested #arguments .validatorType # is not a valid validator" ,type = " ValidationManager.InvalidValidatorType" );
194
195
}
195
196
}
0 commit comments