Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

Commit fd9a03e

Browse files
committed
fix(httpBackend): fix 'type mismatch' error on IE8 after each request
1 parent 6c17d02 commit fd9a03e

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/ng/httpBackend.js

+3-1
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,9 @@ function createHttpBackend($browser, createXhr, $browserDefer, callbacks, rawDoc
7575
// onreadystatechange might by called multiple times
7676
// with readyState === 4 on mobile webkit caused by
7777
// xhrs that are resolved while the app is in the background (see #5426).
78-
xhr.onreadystatechange = undefined;
78+
//
79+
// we must delete the property instead of setting it to undefined/null to make IE8 happy.
80+
delete xhr.onreadystatechange;
7981

8082
var responseHeaders = null,
8183
response = null;

0 commit comments

Comments
 (0)