You've already forked matrix-react-sdk
mirror of
https://github.com/matrix-org/matrix-react-sdk.git
synced 2025-11-11 20:22:36 +03:00
allow logout dialog to be cancelled (can't see why not?)
This commit is contained in:
@@ -39,14 +39,15 @@ export default (props) => {
|
|||||||
const onFinished = (confirmed) => {
|
const onFinished = (confirmed) => {
|
||||||
if (confirmed) {
|
if (confirmed) {
|
||||||
dis.dispatch({action: 'logout'});
|
dis.dispatch({action: 'logout'});
|
||||||
|
}
|
||||||
|
// close dialog
|
||||||
if (props.onFinished) {
|
if (props.onFinished) {
|
||||||
props.onFinished();
|
props.onFinished();
|
||||||
}
|
}
|
||||||
}
|
|
||||||
};
|
};
|
||||||
|
|
||||||
return (<QuestionDialog
|
return (<QuestionDialog
|
||||||
hasCancelButton={false}
|
hasCancelButton={true}
|
||||||
title={_t("Sign out")}
|
title={_t("Sign out")}
|
||||||
description={<div>{description}</div>}
|
description={<div>{description}</div>}
|
||||||
button={_t("Sign out")}
|
button={_t("Sign out")}
|
||||||
|
|||||||
Reference in New Issue
Block a user