Skip to content
This repository has been archived by the owner on Jan 17, 2023. It is now read-only.

Commit

Permalink
Merge pull request #4392 from mozilla-services/3593-raven-monkeypatch
Browse files Browse the repository at this point in the history
Fix #3593, Remove obsolete monkeypatch for install-raven.js
  • Loading branch information
ianb committed May 7, 2018
2 parents db9a082 + c0a43a7 commit fe3e3b1
Showing 1 changed file with 0 additions and 11 deletions.
11 changes: 0 additions & 11 deletions server/src/server.js
Original file line number Diff line number Diff line change
Expand Up @@ -357,19 +357,8 @@ app.get("/install-raven.js", function(req, res) {
sanitizeKeys: ["url"],
serverName: req.backend
};
// FIXME: this monkeypatch is because our version of Raven (6.2) doesn't really work
// with our version of Sentry (8.3.3)
const script = `
${ravenClientJs}
(function () {
var old_captureException = Raven.captureException.bind(Raven);
Raven.captureException = function (ex, options) {
options = options || {};
options.message = options.message || ex.message;
return old_captureException(ex, options);
};
})();
Raven.config("${req.config.sentryPublicDSN}", ${JSON.stringify(options)}).install();
window.Raven = Raven;`;
jsResponse(res, script);
Expand Down

0 comments on commit fe3e3b1

Please sign in to comment.