diff --git a/src/Miscellaneous/ExpandThread.coffee b/src/Miscellaneous/ExpandThread.coffee index aff64b19b..d86451371 100644 --- a/src/Miscellaneous/ExpandThread.coffee +++ b/src/Miscellaneous/ExpandThread.coffee @@ -77,8 +77,6 @@ ExpandThread = postsCount = 0 filesCount = 0 for reply in replies - # rm elements above post such as unread line - $.rm node while (node = a.nextSibling) and node isnt reply # rm clones inlined.click() while inlined = $ '.inlined', reply if Conf['Quote Inlining'] postsCount++ diff --git a/src/Monitoring/UnreadIndex.coffee b/src/Monitoring/UnreadIndex.coffee index 7490289c7..67e0ff111 100644 --- a/src/Monitoring/UnreadIndex.coffee +++ b/src/Monitoring/UnreadIndex.coffee @@ -14,7 +14,7 @@ UnreadIndex = cb: @node $.on d, 'IndexRefreshInternal', @onIndexRefresh - $.on d, 'PostsInserted', @onPostsInserted + $.on d, 'PostsInserted PostsRemoved', @onPostsInserted node: -> UnreadIndex.lastReadPost[@fullID] = UnreadIndex.db.get( @@ -36,7 +36,7 @@ UnreadIndex = return if !thread or thread.nodes.root isnt e.target wasVisible = !!UnreadIndex.hr[thread.fullID]?.parentNode UnreadIndex.update thread - if Conf['Scroll to Last Read Post'] and !wasVisible and !!UnreadIndex.hr[thread.fullID]?.parentNode + if Conf['Scroll to Last Read Post'] and e.type is 'PostsInserted' and !wasVisible and !!UnreadIndex.hr[thread.fullID]?.parentNode Header.scrollToIfNeeded UnreadIndex.hr[thread.fullID], true sync: ->