|
1 |
| -/*! Raven.js 3.0.3 (3738576) | github.com/getsentry/raven-js */ |
| 1 | +/*! Raven.js 3.0.4 (0784c3c) | github.com/getsentry/raven-js */ |
2 | 2 |
|
3 | 3 | /*
|
4 | 4 | * Includes TraceKit
|
@@ -150,7 +150,7 @@ Raven.prototype = {
|
150 | 150 | // webpack (using a build step causes webpack #1617). Grunt verifies that
|
151 | 151 | // this value matches package.json during build.
|
152 | 152 | // See: https://github.com/getsentry/raven-js/issues/465
|
153 |
| - VERSION: '3.0.3', |
| 153 | + VERSION: '3.0.4', |
154 | 154 |
|
155 | 155 | debug: false,
|
156 | 156 |
|
@@ -778,9 +778,9 @@ Raven.prototype = {
|
778 | 778 | // Use only the path component of the URL if the URL matches the current
|
779 | 779 | // document (almost all the time when using pushState)
|
780 | 780 | if (parsedLoc.protocol === parsedTo.protocol && parsedLoc.host === parsedTo.host)
|
781 |
| - to = parsedTo.path; |
| 781 | + to = parsedTo.relative; |
782 | 782 | if (parsedLoc.protocol === parsedFrom.protocol && parsedLoc.host === parsedFrom.host)
|
783 |
| - from = parsedFrom.path; |
| 783 | + from = parsedFrom.relative; |
784 | 784 |
|
785 | 785 | this.captureBreadcrumb({
|
786 | 786 | category: 'navigation',
|
@@ -1357,9 +1357,6 @@ Raven.prototype = {
|
1357 | 1357 | _makeRequest: function(opts) {
|
1358 | 1358 | var request = new XMLHttpRequest();
|
1359 | 1359 |
|
1360 |
| - if (request.send.toString() === 'function send() { [native code] }') { |
1361 |
| - throw new Error('shouldnt get here'); |
1362 |
| - } |
1363 | 1360 | // if browser doesn't support CORS (e.g. IE7), we are out of luck
|
1364 | 1361 | var hasCORS =
|
1365 | 1362 | 'withCredentials' in request ||
|
@@ -1581,10 +1578,15 @@ function urlencode(o) {
|
1581 | 1578 | function parseUrl(url) {
|
1582 | 1579 | var match = url.match(/^(([^:\/?#]+):)?(\/\/([^\/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?$/);
|
1583 | 1580 | if (!match) return {};
|
| 1581 | + |
| 1582 | + // coerce to undefined values to empty string so we don't get 'undefined' |
| 1583 | + var query = match[6] || ''; |
| 1584 | + var fragment = match[8] || ''; |
1584 | 1585 | return {
|
1585 | 1586 | protocol: match[2],
|
1586 | 1587 | host: match[4],
|
1587 |
| - path: match[5] |
| 1588 | + path: match[5], |
| 1589 | + relative: match[5] + query + fragment // everything minus origin |
1588 | 1590 | };
|
1589 | 1591 | }
|
1590 | 1592 | function uuid4() {
|
|
0 commit comments