We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 149a6c9 commit 32e4d83Copy full SHA for 32e4d83
src/raven.js
@@ -637,9 +637,20 @@ Raven.prototype = {
637
638
self._lastCapturedEvent = evt;
639
var elem = evt.target;
640
+
641
+ var target;
642
643
+ // try/catch htmlTreeAsString because it's particularly complicated, and
644
+ // just accessing the DOM incorrectly can throw an exception in some circumstances.
645
+ try {
646
+ target = htmlTreeAsString(elem);
647
+ } catch (e) {
648
+ target = '<unknown>';
649
+ }
650
651
self.captureBreadcrumb('ui_event', {
652
type: evtName,
- target: htmlTreeAsString(elem)
653
+ target: target
654
});
655
};
656
},
0 commit comments