about summary refs log tree commit diff
diff options
context:
space:
mode:
authorThibaut Girka <thib@sitedethib.com>2018-11-30 12:24:58 +0100
committerThibG <thib@sitedethib.com>2018-11-30 22:37:38 +0100
commit31599ad91cd918a8d0cdb8afd1389c206fbc2a1a (patch)
treeb9d20abee41c12fa239c767ade5067821ccc628a
parent837ea32c88f75cac4a83f4449161e0d2d81a6cd2 (diff)
[Glitch] Fix bug in order of conversations in web UI
Port e18390cfe6f5f0eb55abafe072b14b7fa123e808 to glitch-soc
-rw-r--r--app/javascript/flavours/glitch/features/status/index.js7
1 files changed, 5 insertions, 2 deletions
diff --git a/app/javascript/flavours/glitch/features/status/index.js b/app/javascript/flavours/glitch/features/status/index.js
index c1ff5513a..a96c8a1b9 100644
--- a/app/javascript/flavours/glitch/features/status/index.js
+++ b/app/javascript/flavours/glitch/features/status/index.js
@@ -80,9 +80,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);
             });
           }