FIX: Topic timeline not updating in megatopics. (#14645)

FIX: Topic timeline not updating in megatopics. (#14645)

Before this fix, jumping to posts using the topic timeline scrollbar will not update the counts since the topic scrollarea is not rerendered.

Follow-up to db337b10ee2af66f464082ca24bb33536da5fbde

diff --git a/app/assets/javascripts/discourse/app/widgets/topic-timeline.js b/app/assets/javascripts/discourse/app/widgets/topic-timeline.js
index 28437a7..f5b6765 100644
--- a/app/assets/javascripts/discourse/app/widgets/topic-timeline.js
+++ b/app/assets/javascripts/discourse/app/widgets/topic-timeline.js
@@ -555,7 +555,7 @@ export default createWidget("topic-timeline", {
     if (!attrs.mobileView) {
       const streamLength = attrs.topic.get("postStream.stream.length");
 
-      if (streamLength < 2) {
+      if (streamLength === 1) {
         const postsWrapper = document.querySelector(".posts-wrapper");
         if (postsWrapper && postsWrapper.offsetHeight < 1000) {
           displayTimeLineScrollArea = false;

GitHub sha: e74e3fa043efd419c79ce46a9f5214836753cc18

This commit appears in #14645 which was approved by davidtaylorhq. It was merged by tgxworld.