ErrorOccurredInput.fromJson constructor

ErrorOccurredInput.fromJson(
  1. Map<String, dynamic> json
)

Implementation

factory ErrorOccurredInput.fromJson(Map<String, dynamic> json) {
  return ErrorOccurredInput(
    timestamp: json['timestamp'] as num? ?? 0,
    cwd: json['cwd'] as String? ?? '',
    error: json['error'] as String? ?? json['message'] as String? ?? '',
    errorContext: json['errorContext'] as String? ??
        json['errorType'] as String? ??
        'system',
    recoverable: json['recoverable'] as bool? ?? false,
  );
}