validate method

String validate({
  1. String value = '',
})

Implementation

String validate({String value = ''}) {
  if (this.isEmptyOrNull) {
    return value;
  } else {
    return this!;
  }
}