stringNotEmpty static method

String? stringNotEmpty(
  1. String? string, {
  2. String msg = 'O campo não pode ser vazio.',
})

Implementation

static String? stringNotEmpty(
  String? string, {
  String msg = 'O campo não pode ser vazio.',
}) =>
    string != null && string.isNotEmpty ? null : msg;