feat: Clear servers before updating subscription

This commit is contained in:
arm64v8a
2022-10-30 13:15:08 +09:00
parent 91f016bdb2
commit 474e33a32a
6 changed files with 34 additions and 5 deletions

View File

@@ -357,6 +357,14 @@ namespace NekoRay::sub {
group->info = sub_user_info;
group->order.clear();
group->Save();
//
if (dataStore->sub_clear) {
showLog(QObject::tr("Clearing servers..."));
for (const auto &profile: in) {
profileManager->DeleteProfile(profile->id);
}
in = {};
}
}
// 解析并添加 profile