From 64991aefafd9d978299ca13f301363bb18fb13d0 Mon Sep 17 00:00:00 2001 From: James Campos Date: Sat, 9 Oct 2010 00:21:00 -0700 Subject: [PATCH] clear textarea on successful qr --- 4chan_x.coffee | 4 +++- 4chan_x.js | 6 +++--- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/4chan_x.coffee b/4chan_x.coffee index 22f70a892..44120867d 100644 --- a/4chan_x.coffee +++ b/4chan_x.coffee @@ -424,7 +424,9 @@ iframeLoad = -> className: 'error' } qr.appendChild(span) - else unless getConfig('Persistent QR') and REPLY + else if REPLY and getConfig('Persistent QR') + $('textarea', qr).value = '' + else remove qr window.location = 'javascript:Recaptcha.reload()' diff --git a/4chan_x.js b/4chan_x.js index b9c35b401..c1dcf8d26 100644 --- a/4chan_x.js +++ b/4chan_x.js @@ -464,10 +464,10 @@ className: 'error' }); qr.appendChild(span); + } else if (REPLY && getConfig('Persistent QR')) { + $('textarea', qr).value = ''; } else { - if (!(getConfig('Persistent QR') && REPLY)) { - remove(qr); - } + remove(qr); } return (window.location = 'javascript:Recaptcha.reload()'); };