Show compose form on delete & redraft when in mobile layout (#8277)

Fix #8274
This commit is contained in:
Eugen Rochko authored and GitHub committed 2018-08-19 03:17:01 +02:00
1 parent f13afa1ee9
commit 025fbb8285
5 files changed
+15 -11

No files matched your search

@@ -93,14 +93,14 @@ const mapDispatchToProps = (dispatch, { intl }) => ({
}));
},
onDelete (status, withRedraft = false) {
onDelete (status, history, withRedraft = false) {
if (!deleteModal) {
dispatch(deleteStatus(status.get('id'), withRedraft));
dispatch(deleteStatus(status.get('id'), history, withRedraft));
} else {
dispatch(openModal('CONFIRM', {
message: intl.formatMessage(withRedraft ? messages.redraftMessage : messages.deleteMessage),
confirm: intl.formatMessage(withRedraft ? messages.redraftConfirm : messages.deleteConfirm),
onConfirm: () => dispatch(deleteStatus(status.get('id'), withRedraft)),
onConfirm: () => dispatch(deleteStatus(status.get('id'), history, withRedraft)),
}));
}
},