From 267c086c1d09f3555b3c650fcbd5ffe0b9110e93 Mon Sep 17 00:00:00 2001 From: Nicolas Stepien Date: Sat, 19 May 2012 06:27:50 +0200 Subject: [PATCH] Fix MD5 saucing. --- 4chan_x.user.js | 2 +- script.coffee | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/4chan_x.user.js b/4chan_x.user.js index b8c693d02..1f91c4025 100644 --- a/4chan_x.user.js +++ b/4chan_x.user.js @@ -2699,7 +2699,7 @@ case '$2': return "' + img.href + '"; case '$3': - return "' + img.firstChild.dataset.md5.replace(/\=*$/, '') + '"; + return "' + encodeURIComponent(img.firstChild.dataset.md5) + '"; case '$4': return g.BOARD; } diff --git a/script.coffee b/script.coffee index 0bf1ce2f9..cb4992f33 100644 --- a/script.coffee +++ b/script.coffee @@ -2113,7 +2113,7 @@ Sauce = when '$2' "' + img.href + '" when '$3' - "' + img.firstChild.dataset.md5.replace(/\=*$/, '') + '" + "' + encodeURIComponent(img.firstChild.dataset.md5) + '" when '$4' g.BOARD href = Function 'img', "return '#{href}'"