notNull function

String notNull (
  1. dynamic fieldValue,
  2. {String message}
)

Checks if the given value is not null.

Implementation

String notNull(
  dynamic fieldValue, {
  String message,
}) {
  if (fieldValue != null) {
    return null;
  }
  return message ?? 'Please enter a value';
}