From b5a9e1a73af2b2d2f9313afe43c8074257186a9e Mon Sep 17 00:00:00 2001 From: sethkfman Date: Tue, 1 Aug 2023 16:23:10 -0600 Subject: [PATCH] updated with comments and removed console.log --- app/util/sentryUtils.js | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/app/util/sentryUtils.js b/app/util/sentryUtils.js index f5db117adc2..a1556d425db 100644 --- a/app/util/sentryUtils.js +++ b/app/util/sentryUtils.js @@ -72,6 +72,11 @@ function simplifyErrorMessages(report) { }); } +/** + * This function updates the request URL in the error report. + * It will take the origin and if there is none the with will provide "metamask-mobile" + * @param {Object} report + */ function rewriteReportUrls(report) { // update request url console.log('rewriteReportUrls', report); @@ -98,9 +103,7 @@ function toMetamaskUrl(origUrl) { return metamaskUrl; } - function rewriteReport(report) { - console.log('start', report.exception.values[0].stacktrace.frames); try { // simplify certain complex error messages (e.g. Ethjs) simplifyErrorMessages(report); @@ -122,8 +125,6 @@ function rewriteReport(report) { throw err; } - console.log('Report', report.exception.values[0].stacktrace.frames); - return report; }