getInternalError function

ErrorResponse getInternalError(
  1. InternalErrorKey key, {
  2. String? context,
})

Implementation

ErrorResponse getInternalError(InternalErrorKey key, {String? context}) {
  final error = INTERNAL_ERRORS[key]!;
  return ErrorResponse(
    message: context != null ? '${error.message} $context' : error.message,
    code: error.code,
  );
}