Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
const client = Raven.config(ravenTarget, {
release,
transport: function(opts) {
// modify report urls
const report = opts.data
rewriteReportUrls(report)
// make request normally
client._makeRequest(opts)
}
})
client.install()
function rewriteReportUrls(report) {
// update request url
report.request.url = transformUrl(report.request.url)
// update exception stack trace
report.exception.values.forEach(item => {
item.stacktrace.frames.forEach(frame => {
frame.filename = transformUrl(frame.filename)
})
})
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.