call method

  1. @override
String? call(
  1. String? value
)
override

call is a special function that makes a class callable returns null if the input is valid otherwise it returns the provided error errorText

Implementation

@override
String? call(String? value) {
  return (ignoreEmptyValues && value!.isEmpty) ? null : super.call(value);
}