about summary refs log tree commit diff
diff options
context:
space:
mode:
authorEugen Rochko <eugen@zeonfederated.com>2018-06-04 04:19:16 +0200
committerGitHub <noreply@github.com>2018-06-04 04:19:16 +0200
commite18390cfe6f5f0eb55abafe072b14b7fa123e808 (patch)
tree46edf3f8180d6aafe63a62cd54bad85965bc83fd
parent22caa32ba2cb0c0cb87a1e721bd333af3c53cdbb (diff)
Fix bug in order of conversations in web UI (#7721)
-rw-r--r--app/javascript/mastodon/features/status/index.js7
1 files changed, 5 insertions, 2 deletions
diff --git a/app/javascript/mastodon/features/status/index.js b/app/javascript/mastodon/features/status/index.js
index 505a88a3f..96144b19e 100644
--- a/app/javascript/mastodon/features/status/index.js
+++ b/app/javascript/mastodon/features/status/index.js
@@ -77,9 +77,12 @@ const makeMapStateToProps = () => {
           let id        = ids.shift();
           const replies = state.getIn(['contexts', 'replies', id]);
 
+          if (status.get('id') !== id) {
+            mutable.push(id);
+          }
+
           if (replies) {
-            replies.forEach(reply => {
-              mutable.push(reply);
+            replies.reverse().forEach(reply => {
               ids.unshift(reply);
             });
           }