1
0
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:
Bruno Windels
2018-12-11 12:43:56 +01:00
parent fc57109c54
commit a31dacc4bc

View File

@@ -39,14 +39,15 @@ export default (props) => {
const onFinished = (confirmed) => {
if (confirmed) {
dis.dispatch({action: 'logout'});
if (props.onFinished) {
props.onFinished();
}
}
// close dialog
if (props.onFinished) {
props.onFinished();
}
};
return (<QuestionDialog
hasCancelButton={false}
hasCancelButton={true}
title={_t("Sign out")}
description={<div>{description}</div>}
button={_t("Sign out")}