From cd88f81230cee02d148b7240968c4275710a6c0f Mon Sep 17 00:00:00 2001 From: ccd0 Date: Wed, 25 Mar 2015 23:31:27 -0700 Subject: [PATCH] More accurate test for dumping to a thread from the index. --- src/Posting/QR.coffee | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/Posting/QR.coffee b/src/Posting/QR.coffee index fae04f21a..0835e5d9e 100644 --- a/src/Posting/QR.coffee +++ b/src/Posting/QR.coffee @@ -748,6 +748,8 @@ QR = postsCount = QR.posts.length - 1 QR.cooldown.auto = postsCount and isReply + lastPostToThread = not (do -> return true for p in QR.posts[1..] when p.thread is post.thread) + unless Conf['Persistent QR'] or postsCount QR.close() else @@ -758,7 +760,7 @@ QR = URL = if threadID is postID # new thread "#{window.location.origin}/#{g.BOARD}/thread/#{threadID}" - else if g.VIEW is 'index' and !QR.cooldown.auto and Conf['Open Post in New Tab'] # replying from the index + else if g.VIEW is 'index' and lastPostToThread and Conf['Open Post in New Tab'] # replying from the index "#{window.location.origin}/#{g.BOARD}/thread/#{threadID}#p#{postID}" if URL