|
@@ -538,13 +538,18 @@ export class Client {
|
|
|
errorReason,
|
|
|
});
|
|
|
|
|
|
+ const responseTextUndefined = responseText === undefined;
|
|
|
+ const fingerprint = responseTextUndefined
|
|
|
+ ? '200 with undefined responseText'
|
|
|
+ : '200 as error';
|
|
|
+ const message = responseTextUndefined
|
|
|
+ ? '200 API response with undefined responseText'
|
|
|
+ : '200 treated as error';
|
|
|
+
|
|
|
// Make sure all of these errors group, so we don't produce a bunch of noise
|
|
|
- scope.setFingerprint(['200 as error']);
|
|
|
+ scope.setFingerprint([fingerprint]);
|
|
|
|
|
|
- Sentry.captureException(
|
|
|
- new Error(`200 treated as error: ${method} ${path}`),
|
|
|
- scope
|
|
|
- );
|
|
|
+ Sentry.captureException(new Error(`${message}: ${method} ${path}`), scope);
|
|
|
}
|
|
|
|
|
|
const shouldSkipErrorHandler =
|