SentryFeedback.fromJson constructor

SentryFeedback.fromJson(
  1. Map<String, dynamic> data
)

Deserializes a SentryFeedback from JSON Map.

Implementation

factory SentryFeedback.fromJson(Map<String, dynamic> data) {
  final json = AccessAwareMap(data);

  String? associatedEventId = json['associated_event_id'];

  return SentryFeedback(
    message: json['message'],
    contactEmail: json['contact_email'],
    name: json['name'],
    replayId: json['replay_id'],
    url: json['url'],
    associatedEventId:
        associatedEventId != null ? SentryId.fromId(associatedEventId) : null,
    unknown: json.notAccessed(),
  );
}