From 2284fac63257eb6f25fb37b986d0e04a6fe00c14 Mon Sep 17 00:00:00 2001 From: Jeff Becker Date: Sat, 30 Sep 2017 12:11:58 -0400 Subject: [PATCH] fix js --- contrib/static/overchan.js | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/contrib/static/overchan.js b/contrib/static/overchan.js index b405ab5..d6a3c58 100644 --- a/contrib/static/overchan.js +++ b/contrib/static/overchan.js @@ -131,10 +131,6 @@ onready(function() { console.log(msg, j.url); e.innerHTML = msg; if(window.location.pathname === j.url) { - setTimeout(function() { - e.disabled = false; - e.innerHTML = origText; - }, 1000); var img = document.getElementById("captcha_img"); if (img) { reloadImg(img); @@ -143,7 +139,13 @@ onready(function() { } else if (j && j.url) { // do redirect window.location.pathname = j.url; + return; } + setTimeout(function() { + e.disabled = false; + e.innerHTML = origText; + }, 1000); + }); } }