refactor: 整理重构下载任务调度部分的代码,增强可读性和鲁棒性 (#531)

This commit is contained in:
ᴀᴍᴛᴏᴀᴇʀ
2025-11-11 01:29:52 +08:00
committed by GitHub
parent 8931cb5d2a
commit 670f21a725
6 changed files with 250 additions and 192 deletions
+2 -2
View File
@@ -1,5 +1,5 @@
use std::path::PathBuf;
use std::sync::LazyLock;
use std::sync::{Arc, LazyLock};
use anyhow::{Result, bail};
use croner::parser::CronParser;
@@ -31,7 +31,7 @@ pub struct Config {
pub video_name: String,
pub page_name: String,
#[serde(default)]
pub notifiers: Option<Vec<Notifier>>,
pub notifiers: Option<Arc<Vec<Notifier>>>,
#[serde(default = "default_favorite_path")]
pub favorite_default_path: String,
#[serde(default = "default_collection_path")]