From a567752ba1f6c963917db36ff416097a02e0c79e Mon Sep 17 00:00:00 2001 From: ccd0 Date: Sat, 2 Apr 2016 23:55:03 -0700 Subject: [PATCH] Fix errors from changing the Threading checkbox while loading page. --- src/Quotelinks/QuoteThreading.coffee | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/Quotelinks/QuoteThreading.coffee b/src/Quotelinks/QuoteThreading.coffee index 6ed742c25..869de08e1 100644 --- a/src/Quotelinks/QuoteThreading.coffee +++ b/src/Quotelinks/QuoteThreading.coffee @@ -20,6 +20,7 @@ QuoteThreading = $.on @input, 'change', $.cb.checked $.on @input, 'change', @rethread $.on @threadNewLink.firstElementChild, 'click', @rethread + $.on d, '4chanXInitFinished', => @ready = true Header.menu.addEntry @entry = el: @controls @@ -110,6 +111,7 @@ QuoteThreading = return true rethread: -> + return unless QuoteThreading.ready {thread} = QuoteThreading {posts} = thread