@honeybadger-io/js 6.0.0 → 6.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -357,6 +357,7 @@
357
357
  if (notice.cause) {
358
358
  var causes = [];
359
359
  var cause = notice;
360
+ // @ts-ignore this throws an error if tsconfig.json has strict: true
360
361
  while (causes.length < 3 && (cause = cause.cause)) {
361
362
  causes.push({
362
363
  class: cause.name,
@@ -800,7 +801,7 @@
800
801
  var notifier = {
801
802
  name: 'honeybadger-js',
802
803
  url: 'https://github.com/honeybadger-io/honeybadger-js',
803
- version: '6.0.0'
804
+ version: '6.1.1'
804
805
  };
805
806
  // Split at commas and spaces
806
807
  var TAG_SEPARATOR = /,|\s+/;
@@ -1590,7 +1591,9 @@
1590
1591
  return function () {
1591
1592
  // eslint-disable-next-line @typescript-eslint/no-this-alias
1592
1593
  var xhr = this;
1593
- var url = arguments[1];
1594
+ var rawUrl = arguments[1];
1595
+ // in case of url being URL object (which is valid input) we need to stringify it
1596
+ var url = typeof rawUrl === 'string' ? rawUrl : String(rawUrl);
1594
1597
  var method = typeof arguments[0] === 'string' ? arguments[0].toUpperCase() : arguments[0];
1595
1598
  var message = "".concat(method, " ").concat((0, util_1$3.localURLPathname)(url));
1596
1599
  this.__hb_xhr = {