Merge pull request #2922 from overleaf/jpa-fix-sentry-frontend

[misc] fix sentry integration for the frontend

GitOrigin-RevId: 269eb3c538e1dc891c4598b608b3392ee22320e0
This commit is contained in:
Jakob Ackermann 2020-06-23 15:15:09 +02:00 committed by Copybot
parent 2e0db2a472
commit ae327e7fd0
3 changed files with 6 additions and 9 deletions

View file

@ -22,10 +22,6 @@ import './modules/recursionHelper'
import './modules/errorCatcher'
import './modules/localStorage'
import './modules/sessionStorage'
// Configure dynamically loaded assets (via webpack) to be downloaded from CDN
// See: https://webpack.js.org/guides/public-path/#on-the-fly
// eslint-disable-next-line no-undef
__webpack_public_path__ = window.baseAssetPath
const App = angular
.module('SharelatexApp', [

View file

@ -10,3 +10,8 @@ import 'libs/angular-cookie'
import 'libs/passfield'
import 'libs/ng-tags-input-3.0.0'
import 'libs/select/select'
// Configure dynamically loaded assets (via webpack) to be downloaded from CDN
// See: https://webpack.js.org/guides/public-path/#on-the-fly
// eslint-disable-next-line no-undef, camelcase
__webpack_public_path__ = window.baseAssetPath

View file

@ -32,11 +32,7 @@ if (window.ExposedSettings.sentryDsn) {
}
})
Sentry.configureScope(scope => {
if (window.user_id.length) {
scope.setUser(window.user_id)
}
})
Sentry.setUser({ id: window.user_id })
// Previously Raven added itself as a global, so we mimic that old behaviour
window.Raven = Sentry