run<TValue> static method
Runs all validators
on value
, then return the error message or
null
accordingly.
Implementation
static String? run<TValue>(
List<LoFieldBaseValidator> validators,
TValue value,
) {
for (final validator in validators) {
final error = validator.validate(value);
if (error != null) return error;
}
return null;
}