refactor(core): Stop reporting to Sentry NodeApiError with 5xx status codes (no-changelog) (#9552)

This commit is contained in:
Iván Ovejero 2024-05-30 16:44:01 +02:00 committed by GitHub
parent be5890536f
commit dda56aa6d3
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -188,11 +188,7 @@ export class NodeApiError extends NodeError {
this.findProperty(errorResponse, ERROR_STATUS_PROPERTIES, ERROR_NESTING_PROPERTIES) ?? null;
}
if (level) {
this.level = level;
} else if (this.httpCode?.charAt(0) !== '5') {
this.level = 'warning';
}
this.level = level ?? 'warning';
if (
errorResponse?.response &&