Fix previous tweak.

This commit is contained in:
Nicolas Stepien 2012-09-07 22:22:58 +02:00
parent 063ea136ba
commit d846449d19
2 changed files with 4 additions and 3 deletions

View File

@ -2852,13 +2852,14 @@
this.unsuccessfulFetchCount = 0; this.unsuccessfulFetchCount = 0;
this.lastModified = '0'; this.lastModified = '0';
$.ajax("//api.4chan.org/" + g.BOARD + "/res/" + g.THREAD_ID + ".json", { $.ajax("//api.4chan.org/" + g.BOARD + "/res/" + g.THREAD_ID + ".json", {
type: 'head',
onload: function() { onload: function() {
if (this.status !== 200) { if (this.status !== 200) {
return; return;
} }
return Updater.lastModified = this.getResponseHeader('Last-Modified'); return Updater.lastModified = this.getResponseHeader('Last-Modified');
} }
}, {
type: 'head'
}); });
_ref = $$('input', dialog); _ref = $$('input', dialog);
for (_i = 0, _len = _ref.length; _i < _len; _i++) { for (_i = 0, _len = _ref.length; _i < _len; _i++) {

View File

@ -2281,11 +2281,11 @@ Updater =
@unsuccessfulFetchCount = 0 @unsuccessfulFetchCount = 0
@lastModified = '0' @lastModified = '0'
$.ajax "//api.4chan.org/#{g.BOARD}/res/#{g.THREAD_ID}.json", $.ajax "//api.4chan.org/#{g.BOARD}/res/#{g.THREAD_ID}.json", {
type: 'head'
onload: -> onload: ->
return if @status isnt 200 return if @status isnt 200
Updater.lastModified = @getResponseHeader 'Last-Modified' Updater.lastModified = @getResponseHeader 'Last-Modified'
}, type: 'head'
for input in $$ 'input', dialog for input in $$ 'input', dialog
if input.type is 'checkbox' if input.type is 'checkbox'