Index should also rebuild posts from quote fetching.
As was done for thread expansion in 184141a5e0c5c1da2ac85c8d0c550bfb24b02577.
This commit is contained in:
parent
a5f4915e51
commit
ecead5f7e8
@ -4,7 +4,7 @@ ThreadHiding =
|
||||
@db = new DataBoard 'hiddenThreads'
|
||||
return @catalogWatch() if g.VIEW is 'catalog'
|
||||
@catalogSet g.BOARD
|
||||
Thread.callbacks.push
|
||||
Post.callbacks.push
|
||||
name: 'Thread Hiding'
|
||||
cb: @node
|
||||
|
||||
@ -38,10 +38,13 @@ ThreadHiding =
|
||||
ThreadHiding.hiddenThreads = hiddenThreads2
|
||||
|
||||
node: ->
|
||||
return if @isReply or @isClone or @isFetchedQuote
|
||||
|
||||
if data = ThreadHiding.db.get {boardID: @board.ID, threadID: @ID}
|
||||
ThreadHiding.hide @, data.makeStub
|
||||
ThreadHiding.hide @thread, data.makeStub
|
||||
|
||||
return unless Conf['Thread Hiding Buttons']
|
||||
$.prepend @OP.nodes.root, ThreadHiding.makeButton @, 'hide'
|
||||
$.prepend @nodes.root, ThreadHiding.makeButton(@thread, 'hide')
|
||||
|
||||
onIndexBuild: (nodes) ->
|
||||
for root in nodes
|
||||
|
||||
@ -276,7 +276,10 @@ Build =
|
||||
thread: (board, data, full) ->
|
||||
Build.spoilerRange[board] = data.custom_spoiler
|
||||
|
||||
if (OP = board.posts[data.no]) and root = OP.nodes.root.parentNode
|
||||
if OP = board.posts[data.no]
|
||||
OP = null if OP.isFetchedQuote
|
||||
|
||||
if OP and (root = OP.nodes.root.parentNode)
|
||||
$.rmAll root
|
||||
else
|
||||
root = $.el 'div',
|
||||
|
||||
@ -517,7 +517,7 @@ Index =
|
||||
thread = new Thread threadData.no, g.BOARD
|
||||
threads.push thread
|
||||
Index.nodes.push threadRoot
|
||||
unless thread.ID of thread.posts
|
||||
unless thread.OP and not thread.OP.isFetchedQuote
|
||||
posts.push new Post $('.opContainer', threadRoot), thread, g.BOARD
|
||||
thread.setPage i // Index.threadsNumPerPage + 1
|
||||
catch err
|
||||
@ -543,7 +543,7 @@ Index =
|
||||
continue unless lastReplies = Index.liveThreadData[i].last_replies
|
||||
nodes = []
|
||||
for data in lastReplies
|
||||
if post = thread.posts[data.no]
|
||||
if (post = thread.posts[data.no]) and not post.isFetchedQuote
|
||||
nodes.push post.nodes.root
|
||||
continue
|
||||
nodes.push node = Build.postFromObject data, thread.board.ID
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user