Guard against disabling a not-yet-active catalog.

This commit is contained in:
James Turner 2016-03-30 17:09:33 +01:00
parent 63b2b04977
commit 177c5ec709

View File

@ -532,8 +532,10 @@ void Root::catalogRefreshStatus(CatalogRef aCat, Delegate::StatusCode aReason)
} }
// and remove it from the active collection // and remove it from the active collection
if (catIt != d->catalogs.end()) {
d->catalogs.erase(catIt); d->catalogs.erase(catIt);
} }
} // of catalog has errors case
if (d->refreshing.empty()) { if (d->refreshing.empty()) {
d->fireRefreshStatus(CatalogRef(), Delegate::STATUS_REFRESHED); d->fireRefreshStatus(CatalogRef(), Delegate::STATUS_REFRESHED);