Fixes for logging out the active connection

- Don't crash
- Fall back to WelcomePage
This commit is contained in:
Tobias Fella
2025-09-02 15:36:55 +02:00
committed by Tobias Fella
parent 6c57c41993
commit e8ad4a5dee
2 changed files with 12 additions and 2 deletions

View File

@@ -267,6 +267,17 @@ Kirigami.ApplicationWindow {
}
}
Connections {
target: root.connection
function onLoggedOut(): void {
root.pageStack.clear();
let page = root.pageStack.push(Qt.createComponent('org.kde.neochat.login', 'WelcomePage'), {
showExisting: true,
}) as WelcomePage;
page.connectionChosen.connect(() => root.load())
}
}
Connections {
target: AccountRegistry
function onRowsRemoved() {