Skip to content

Commit

Permalink
Merge pull request #14 from talis/ELE-3421-include-url-in-errors
Browse files Browse the repository at this point in the history
ELE-3421 Include URL in NewRelic error reporting
  • Loading branch information
pads authored Oct 22, 2020
2 parents 1e6557f + a88eefb commit 2f0d34a
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 3 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
## 2.2.1 (2020-10-23)

Improvement:

- Log the browser URL when logging errors and exceptions

## 2.1.6 (2019-12-2)

Improvement:
Expand Down
2 changes: 1 addition & 1 deletion bower.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "app-logger-angular",
"version": "2.2.0",
"version": "2.2.1",
"main": "./js/logging.js",
"description": "Client side logging sent to the server",
"repository": {
Expand Down
4 changes: 2 additions & 2 deletions js/logging.js
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ loggingModule.factory(
}

if (LOGGING_CONFIG.FORWARD_TO_NEWRELIC && $window.NREUM && $window.NREUM.noticeError) {
$window.NREUM.noticeError(exception);
$window.NREUM.noticeError(exception, { url: $window.location.href });
}

// check if the config says we should log to the remote, and also if a remote endpoint was specified
Expand Down Expand Up @@ -149,7 +149,7 @@ loggingModule.factory(
}

if (sendToNewRelic && $window.NREUM && $window.NREUM.noticeError) {
$window.NREUM.noticeError(message, {desc: desc});
$window.NREUM.noticeError(message, { desc: desc, url: $window.location.href });
}

// check if the config says we should log to the remote, and also if a remote endpoint was specified
Expand Down

0 comments on commit 2f0d34a

Please sign in to comment.