diff --git a/4chan_x.user.js b/4chan_x.user.js index bd4141a52..04b2260f4 100644 --- a/4chan_x.user.js +++ b/4chan_x.user.js @@ -3319,6 +3319,9 @@ url = href + '?' + Date.now(); } timeoutID = setTimeout(imgExpand.expand, 10000, thumb, url); + if (!(engine === 'webkit' && url.split('/')[2] === 'image.4chan.org')) { + return; + } return $.ajax(url, { onreadystatechange: (function() { if (this.status === 404) return clearTimeout(timeoutID); diff --git a/script.coffee b/script.coffee index f7211ad63..0d9d26bd7 100644 --- a/script.coffee +++ b/script.coffee @@ -2548,6 +2548,9 @@ imgExpand = url = href + '?' + Date.now() #navigator.online is not x-browser/os yet timeoutID = setTimeout imgExpand.expand, 10000, thumb, url + # Only Chrome let userscript break through cross domain requests. + # Don't check it 404s in the archivers. + return unless engine is 'webkit' and url.split('/')[2] is 'image.4chan.org' $.ajax url, onreadystatechange: (-> clearTimeout timeoutID if @status is 404), type: 'head'