diff --git a/src/appdata/app-data-manager.cpp b/src/appdata/app-data-manager.cpp index ac763b4..e1d2c98 100644 --- a/src/appdata/app-data-manager.cpp +++ b/src/appdata/app-data-manager.cpp @@ -146,6 +146,9 @@ void AppDataWorker::onAppAdded(const QStringList &infos) QList apps; appendApps(infos, apps); + if (apps.isEmpty()) { + return; + } Q_EMIT appAdded(apps); updateFavoriteApps(); @@ -188,6 +191,9 @@ void AppDataWorker::onAppUpdated(const UkuiSearch::ApplicationInfoMap &infos) QList apps; updateApps(infos, apps); + if (apps.isEmpty()) { + return; + } Q_EMIT appUpdated(apps); updateFavoriteApps(); @@ -201,6 +207,9 @@ void AppDataWorker::onAppUpdatedAll(const QStringList &infos) QList apps; updateAppsAll(infos, apps); + if (apps.isEmpty()) { + return; + } Q_EMIT appUpdated(apps); updateFavoriteApps(); @@ -281,6 +290,9 @@ void AppDataWorker::onAppDeleted(QStringList infos) } QStringList removedIdList; removeApps(infos, removedIdList); + if (removedIdList.isEmpty()) { + return; + } Q_EMIT appDeleted(removedIdList); updateFavoriteApps();