feat: Improved error filtering and reporting (#1293)
This commit is contained in:
@@ -93,6 +93,13 @@ if (process.env.SENTRY_DSN) {
|
||||
dsn: process.env.SENTRY_DSN,
|
||||
environment: process.env.NODE_ENV,
|
||||
maxBreadcrumbs: 0,
|
||||
ignoreErrors: [
|
||||
// emitted by Koa when bots attempt to snoop on paths such as wp-admin
|
||||
// or the user submits a bad request. These are expected in normal running
|
||||
// of the application
|
||||
'BadRequestError',
|
||||
'UnauthorizedError',
|
||||
],
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
@@ -40,7 +40,16 @@
|
||||
>
|
||||
</script>
|
||||
<script>
|
||||
Sentry.init({ dsn: '<%= SENTRY_DSN %>' });
|
||||
Sentry.init({
|
||||
dsn: '<%= SENTRY_DSN %>',
|
||||
ignoreErrors: [
|
||||
'AuthorizationError',
|
||||
'NetworkError',
|
||||
'NotFoundError',
|
||||
'OfflineError',
|
||||
'UpdateRequiredError',
|
||||
],
|
||||
});
|
||||
|
||||
if (window.localStorage.getItem("theme") === "dark") {
|
||||
window.document.querySelector('#root').style.background = "#111319";
|
||||
|
||||
Reference in New Issue
Block a user