Commit 72bca354 authored by David Faure's avatar David Faure Committed by Laurent Montel
Browse files

Fix assert when using an empty tab to load a folder

1) create empty tab   -> this calls FolderSettings::setCollection(invalid)
2) switch to folder   -> kmmainwidget calls writeFolderConfig() for the
   old folder (invalid), which calls FolderSettings::resource(), which

There's just nothing to save in such a case, skip saving.
parent 1ead22c4
Pipeline #211672 passed with stage
in 5 minutes and 1 second
......@@ -530,7 +530,7 @@ void KMMainWidget::slotHistorySwitchFolder(const Akonadi::Collection &collection
// Delete any pending timer, if needed it will be recreated below
delete mShowBusySplashTimer;
mShowBusySplashTimer = nullptr;
if (newFolder) {
if (newFolder && mCurrentCollection.isValid()) {
// We're changing folder: write configuration for the old one
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment