Remove routerHistory parameters from composer actions (#31077)
This commit is contained in:
parent
adadfdbc03
commit
e768b23aa9
18 changed files with 91 additions and 100 deletions
|
@ -280,11 +280,11 @@ class Status extends ImmutablePureComponent {
|
|||
modalProps: {
|
||||
message: intl.formatMessage(messages.replyMessage),
|
||||
confirm: intl.formatMessage(messages.replyConfirm),
|
||||
onConfirm: () => dispatch(replyCompose(status, this.props.history)),
|
||||
onConfirm: () => dispatch(replyCompose(status)),
|
||||
},
|
||||
}));
|
||||
} else {
|
||||
dispatch(replyCompose(status, this.props.history));
|
||||
dispatch(replyCompose(status));
|
||||
}
|
||||
} else {
|
||||
dispatch(openModal({
|
||||
|
@ -336,33 +336,33 @@ class Status extends ImmutablePureComponent {
|
|||
}
|
||||
};
|
||||
|
||||
handleDeleteClick = (status, history, withRedraft = false) => {
|
||||
handleDeleteClick = (status, withRedraft = false) => {
|
||||
const { dispatch, intl } = this.props;
|
||||
|
||||
if (!deleteModal) {
|
||||
dispatch(deleteStatus(status.get('id'), history, withRedraft));
|
||||
dispatch(deleteStatus(status.get('id'), withRedraft));
|
||||
} else {
|
||||
dispatch(openModal({
|
||||
modalType: 'CONFIRM',
|
||||
modalProps: {
|
||||
message: intl.formatMessage(withRedraft ? messages.redraftMessage : messages.deleteMessage),
|
||||
confirm: intl.formatMessage(withRedraft ? messages.redraftConfirm : messages.deleteConfirm),
|
||||
onConfirm: () => dispatch(deleteStatus(status.get('id'), history, withRedraft)),
|
||||
onConfirm: () => dispatch(deleteStatus(status.get('id'), withRedraft)),
|
||||
},
|
||||
}));
|
||||
}
|
||||
};
|
||||
|
||||
handleEditClick = (status, history) => {
|
||||
this.props.dispatch(editStatus(status.get('id'), history));
|
||||
handleEditClick = (status) => {
|
||||
this.props.dispatch(editStatus(status.get('id')));
|
||||
};
|
||||
|
||||
handleDirectClick = (account, router) => {
|
||||
this.props.dispatch(directCompose(account, router));
|
||||
handleDirectClick = (account) => {
|
||||
this.props.dispatch(directCompose(account));
|
||||
};
|
||||
|
||||
handleMentionClick = (account, router) => {
|
||||
this.props.dispatch(mentionCompose(account, router));
|
||||
handleMentionClick = (account) => {
|
||||
this.props.dispatch(mentionCompose(account));
|
||||
};
|
||||
|
||||
handleOpenMedia = (media, index, lang) => {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue