mirror of https://github.com/vector-im/riot-web
allow logout dialog to be cancelled (can't see why not?)
parent
fc57109c54
commit
a31dacc4bc
|
@ -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")}
|
||||
|
|
Loading…
Reference in New Issue