Fix thumbnail URL parsing (really diverting to full URL) for spoilered thumbnails on Tinyboard.

This commit is contained in:
ccd0 2018-01-24 02:26:51 -08:00
parent c01296d2af
commit ad9d3b3a8a

View File

@ -119,7 +119,7 @@ SW.tinyboard =
dimensions: info[0].match(/\d+x\d+/)?[0]
if thumb
$.extend file,
thumbURL: if '/static/' in thumb.src then link.href else thumb.src
thumbURL: if /\/static\//.test(thumb.src) and /\.(?:gif|jpe?g|png)$/.test(link.href) then link.href else thumb.src
isSpoiler: !!info[1] or link.textContent is 'Spoiler Image'
true