Skip to content

Commit e65e921

Browse files
Treat a 304 HTTP status as a successful response. [prototypejs#331 state:resolved] (Kenneth Kin Lum, Andrew Dupont)
1 parent 5dc12bd commit e65e921

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

CHANGELOG

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
* Treat a 304 HTTP status as a successful response. [#331 state:resolved] (Kenneth Kin Lum, Andrew Dupont)
2+
13
* Handle sparse arrays properly in `Array#_each` to match behavior with browsers' built-in `Array#forEach` (and ES5). [#790 state:resolved] (Andriy Tyurnikov, Yaffle, Andrew Dupont)
24

35
* Make `Event.extend` work with legacy IE events in IE 9. (Andrew Dupont)

src/ajax/request.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -270,7 +270,7 @@ Ajax.Request = Class.create(Ajax.Base, {
270270
**/
271271
success: function() {
272272
var status = this.getStatus();
273-
return !status || (status >= 200 && status < 300);
273+
return !status || (status >= 200 && status < 300) || status == 304;
274274
},
275275

276276
getStatus: function() {

0 commit comments

Comments
 (0)