diff --git a/src/Lifecycle.js b/src/Lifecycle.js index b35957408e..efd5c20d5c 100644 --- a/src/Lifecycle.js +++ b/src/Lifecycle.js @@ -389,7 +389,7 @@ function _persistCredentialsToLocalStorage(credentials) { * Logs the current session out and transitions to the logged-out state */ export function logout() { - if (!MatrixClientPeg.get()) return + if (!MatrixClientPeg.get()) return; if (MatrixClientPeg.get().isGuest()) { // logout doesn't work for guest sessions