Commit ada8b123 authored by mgabdev's avatar mgabdev

Updated handleComposeSubmit to inject own status into timeline on post

• Updated:
- handleComposeSubmit to inject own status into timeline on post
parent d258cabd
......@@ -11,7 +11,10 @@ import { joinGroup } from './groups'
import { useEmoji } from './emojis';
import resizeImage from '../utils/resize_image';
import { importFetchedAccounts } from './importer';
import { updateTimeline, dequeueTimeline } from './timelines';
import {
updateTimelineQueue,
updateTimeline,
} from './timelines'
// import { showAlert, showAlertForError } from './alerts';
import { defineMessages } from 'react-intl';
import { openModal, closeModal } from './modal';
......@@ -258,7 +261,6 @@ export function handleComposeSubmit(dispatch, getState, response, status) {
const timeline = getState().getIn(['timelines', timelineId]);
if (timeline && timeline.get('items').size > 0 && timeline.getIn(['items', 0]) !== null && timeline.get('online')) {
dispatch(updateTimelineQueue(timelineId, response.data))
dispatch(updateTimeline(timelineId, { ...response.data }));
}
};
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment