Skip to content

Commit

Permalink
Fix issue where an Ajax request in IE sometimes returns 1223 instead …
Browse files Browse the repository at this point in the history
…of 204 as the status code. [#129 state:resolved] (adevadeh, gordyt, Andrew Dupont)
  • Loading branch information
savetheclocktower committed Oct 17, 2010
1 parent 05e0ebc commit 8b2ed97
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG
@@ -1,3 +1,5 @@
* Fix issue where an Ajax request in IE sometimes returns 1223 instead of 204 as the status code. [#129 state:resolved] (adevadeh, gordyt, Andrew Dupont)

* Add Object.isDate. [#443 state:resolved] (Nesterenko Dmitry, kangax, Samuel Lebeau, Andrew Dupont)

* Handle cases where `document` or `document.documentElement` is passed into Element#getOffsetParent. Fixes IE errors with many layout/positioning methods. [#90 state:resolved] (Padraig Kennedy, Andrew Dupont)
Expand Down
2 changes: 2 additions & 0 deletions src/ajax/request.js
Expand Up @@ -278,6 +278,8 @@ Ajax.Request = Class.create(Ajax.Base, {

getStatus: function() {
try {
// IE sometimes returns 1223 for a 204 response.
if (this.transport.status === 1223) return 204;
return this.transport.status || 0;
} catch (e) { return 0 }
},
Expand Down

0 comments on commit 8b2ed97

Please sign in to comment.