-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Vendor+IE8-ify json-stringify-safe, fix handler with XDomainRequest #883
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks fine, I just want to poke at this w/ BrowserStack first.
} | ||
if (opts.onError) { | ||
request.onerror = function () { | ||
var err = new Error('Sentry error code: XDomainRequest'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I quickly experimented w/ having a helper onerror
function that could be called from either the XDomainRequest
handler or onreadystatechange
, but it quickly ended up taking up more code so nm ...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry this took so long to review.
Verified w/ IE8 via Browserstack.
This should fully address #881. There were two symptoms each with a separate root issue:
Object doesn't support this property or method
when sending messages/exceptionsArray.prototype.indexOf
Array.prototype.indexOf
request
object doesn't have astatus
attribute which we were expecting/relying on, andXDR.onload
only fires in success cases (error cases useonerror
)._makeRequest
I pieced this into several separate commits to make it easy to see our modifications relative to the vendored originals.
/cc @benvinegar