validateCheckbox static method

String? validateCheckbox({
  1. bool v = false,
  2. String error = Strings.checkboxValidation,
})

Implementation

static String? validateCheckbox({
  bool v = false,
  String error = Strings.checkboxValidation,
}) {
  if (!v) {
    return error;
  } else {
    return null;
  }
}