mirror of
https://github.com/clash-verge-rev/clash-verge-rev.git
synced 2026-12-04 05:00:05 +08:00
refactor(profile): look up the refresh target once
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
use crate::{
|
||||
config::{Config, PrfOption, download_subscription, prepare_remote_refresh, profiles::apply_remote_refresh_safe},
|
||||
config::{Config, PrfOption, download_subscription, prepare_remote_refresh, profiles::save_remote_refresh},
|
||||
core::{
|
||||
CoreManager, handle,
|
||||
notify::{NoticeStatus, Refresh, announce},
|
||||
@@ -133,7 +133,7 @@ async fn perform_profile_update(
|
||||
"profile source changed during refresh"
|
||||
);
|
||||
let refresh = prepare_remote_refresh(downloaded, merged_opt.as_ref()).await?;
|
||||
apply_remote_refresh_safe(uid, url, refresh).await?;
|
||||
save_remote_refresh(uid, url, refresh).await?;
|
||||
if !matches!(strategy, Strategy::Configured) {
|
||||
handle::Handle::notice(NoticeStatus::UpdateWithClashProxy, profile_name.as_str());
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user