getInternalError static method
Implementation
static Error getInternalError(
String key, {
String context = '',
}) {
if (INTERNAL_ERRORS.containsKey(key)) {
return new Error(
INTERNAL_ERRORS[key]!['code']! as int,
context != ''
? "${INTERNAL_ERRORS[key]!['message']! as String} $context"
: INTERNAL_ERRORS[key]!['message']! as String,
);
}
return new Error(-1, "UNKNOWN INTERNAL ERROR");
}