|
|
@ -7,12 +7,15 @@ const postStatus = ({ store, status, media = [], inReplyToStatusId = undefined }
|
|
|
|
return apiService.postStatus({credentials: store.state.users.currentUser.credentials, status, mediaIds, inReplyToStatusId})
|
|
|
|
return apiService.postStatus({credentials: store.state.users.currentUser.credentials, status, mediaIds, inReplyToStatusId})
|
|
|
|
.then((data) => data.json())
|
|
|
|
.then((data) => data.json())
|
|
|
|
.then((data) => {
|
|
|
|
.then((data) => {
|
|
|
|
store.dispatch('addNewStatuses', {
|
|
|
|
if (!data.error) {
|
|
|
|
statuses: [data],
|
|
|
|
store.dispatch('addNewStatuses', {
|
|
|
|
timeline: 'friends',
|
|
|
|
statuses: [data],
|
|
|
|
showImmediately: true,
|
|
|
|
timeline: 'friends',
|
|
|
|
noIdUpdate: true // To prevent missing notices on next pull.
|
|
|
|
showImmediately: true,
|
|
|
|
})
|
|
|
|
noIdUpdate: true // To prevent missing notices on next pull.
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
return data
|
|
|
|
})
|
|
|
|
})
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|