]> cat aescling's git repositories - mastodon.git/commitdiff
Fixing issue #626
authorRakib Hasan <rmhasan@gmail.com>
Sun, 19 Feb 2017 07:32:35 +0000 (07:32 +0000)
committerRakib Hasan <rmhasan@gmail.com>
Sun, 19 Feb 2017 08:21:05 +0000 (08:21 +0000)
The status is not showing anymore after clicking on it

app/assets/javascripts/components/actions/statuses.jsx
app/assets/javascripts/components/features/status/index.jsx

index ee662fe7913b0803c5ee52f9b6585c2ae7a98ea9..d83edd1454ffbd10451642af9dcc499b9426f04b 100644 (file)
@@ -28,7 +28,6 @@ export function fetchStatus(id) {
     const skipLoading = getState().getIn(['statuses', id], null) !== null;
 
     dispatch(fetchContext(id));
-    dispatch(fetchStatusCard(id));
 
     if (skipLoading) {
       return;
@@ -102,7 +101,10 @@ export function fetchContext(id) {
 
     api(getState).get(`/api/v1/statuses/${id}/context`).then(response => {
       dispatch(fetchContextSuccess(id, response.data.ancestors, response.data.descendants));
+      dispatch(fetchStatusCard(id));
     }).catch(error => {
+      dispatch(deleteStatusSuccess(id));
+      dispatch(deleteFromTimelines(id));
       dispatch(fetchContextFail(id, error));
     });
   };
index e17c078d275049ce159192a03c0486c86efe0ed1..7c9fcef3ddfeb0a68fccfedd3746f27d71e5bcc5 100644 (file)
@@ -117,7 +117,7 @@ const Status = React.createClass({
     if (status === null) {
       return (
         <Column>
-          <LoadingIndicator />
+          <ColumnBackButton />
         </Column>
       );
     }