derp
This commit is contained in:
parent
82743a39dc
commit
c47e058e7c
@ -3452,7 +3452,7 @@
|
|||||||
self = this;
|
self = this;
|
||||||
return $.ajax("https://sys.4chan.org/" + g.BOARD + "/imgboard.php", {
|
return $.ajax("https://sys.4chan.org/" + g.BOARD + "/imgboard.php", {
|
||||||
onload: function() {
|
onload: function() {
|
||||||
return DeleteButton.load(self);
|
return DeleteButton.load(self, this.response);
|
||||||
},
|
},
|
||||||
onerror: function() {
|
onerror: function() {
|
||||||
return DeleteButton.error(self);
|
return DeleteButton.error(self);
|
||||||
@ -3462,10 +3462,10 @@
|
|||||||
form: data
|
form: data
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
load: function(self) {
|
load: function(self, html) {
|
||||||
var doc, msg, tc;
|
var doc, msg, tc;
|
||||||
doc = d.implementation.createHTMLDocument('');
|
doc = d.implementation.createHTMLDocument('');
|
||||||
doc.documentElement.innerHTML = this.response;
|
doc.documentElement.innerHTML = html;
|
||||||
if (doc.title === '4chan - Banned') {
|
if (doc.title === '4chan - Banned') {
|
||||||
tc = 'Banned!';
|
tc = 'Banned!';
|
||||||
} else if (msg = doc.getElementById('errmsg')) {
|
} else if (msg = doc.getElementById('errmsg')) {
|
||||||
|
|||||||
@ -2635,15 +2635,15 @@ DeleteButton =
|
|||||||
data.append 'pwd', pwd
|
data.append 'pwd', pwd
|
||||||
self = this
|
self = this
|
||||||
$.ajax "https://sys.4chan.org/#{g.BOARD}/imgboard.php", {
|
$.ajax "https://sys.4chan.org/#{g.BOARD}/imgboard.php", {
|
||||||
onload: -> DeleteButton.load self
|
onload: -> DeleteButton.load self, @response
|
||||||
onerror: -> DeleteButton.error self
|
onerror: -> DeleteButton.error self
|
||||||
}, {
|
}, {
|
||||||
type: 'post'
|
type: 'post'
|
||||||
form: data
|
form: data
|
||||||
}
|
}
|
||||||
load: (self) ->
|
load: (self, html) ->
|
||||||
doc = d.implementation.createHTMLDocument ''
|
doc = d.implementation.createHTMLDocument ''
|
||||||
doc.documentElement.innerHTML = @response
|
doc.documentElement.innerHTML = html
|
||||||
if doc.title is '4chan - Banned' # Ban/warn check
|
if doc.title is '4chan - Banned' # Ban/warn check
|
||||||
tc = 'Banned!'
|
tc = 'Banned!'
|
||||||
else if msg = doc.getElementById 'errmsg' # error!
|
else if msg = doc.getElementById 'errmsg' # error!
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user