getEntry method

String? getEntry(
  1. int code
)

Implementation

String? getEntry(int code) {
  try {
    if (this.msgs.containsKey(code)) {
      final msg = this.msgs[code]!;

      if (msg.isEmpty) {
        throw Exception();
      }
      return msg;
    } else {
      throw Exception();
    }
  } on Exception {
    return this.msgs[ModErrorCodes.GENERAL];
  }
}