mirror of
https://github.com/nextcloud/desktop.git
synced 2024-11-26 23:28:14 +03:00
Wizard: Detach saved account from wizard
Fixes #5408 #5407.
The problem was that cleanup of the credentials page set the
credentials of the account back to dummy, thereby overriding
things like shib usernames.
This should be broken since a932eac832
.
This commit is contained in:
parent
d781e63fab
commit
3b7887ca35
1 changed files with 7 additions and 0 deletions
|
@ -553,6 +553,13 @@ void OwncloudSetupWizard::slotSkipFolderConfiguration()
|
|||
AccountState *OwncloudSetupWizard::applyAccountChanges()
|
||||
{
|
||||
AccountPtr newAccount = _ocWizard->account();
|
||||
|
||||
// Detach the account that is going to be saved from the
|
||||
// wizard to ensure it doesn't accidentally get modified
|
||||
// later (such as from running cleanup such as
|
||||
// AbstractCredentialsWizardPage::cleanupPage())
|
||||
_ocWizard->setAccount(AccountManager::createAccount());
|
||||
|
||||
auto manager = AccountManager::instance();
|
||||
|
||||
auto newState = manager->addAccount(newAccount);
|
||||
|
|
Loading…
Reference in a new issue