SentryResponse constructor

SentryResponse({
  1. int? bodySize,
  2. int? statusCode,
  3. Map<String, String>? headers,
  4. String? cookies,
})

Implementation

SentryResponse(
    {this.bodySize,
    this.statusCode,
    Map<String, String>? headers,
    String? cookies})
    : _headers = headers != null ? Map.from(headers) : null,
      // Look for a 'Set-Cookie' header (case insensitive) if not given.
      cookies = cookies ??
          headers?.entries
              .firstWhereOrNull((e) => e.key.toLowerCase() == 'set-cookie')
              ?.value;