mirror of
https://github.com/euzu/tuliprox.git
synced 2026-10-04 23:12:27 +02:00
File Lock fix
This commit is contained in:
@@ -108,7 +108,7 @@ where
|
||||
};
|
||||
|
||||
{
|
||||
let file_lock = cfg.file_locks.read_lock(&file_path);
|
||||
let file_lock = cfg.file_locks.read_lock(&file_path).await;
|
||||
if let Ok(info_records) = BPlusTree::<u32, V>::load(&file_path) {
|
||||
info_records.iter().for_each(|(provider_id, record)| {
|
||||
processed_info_ids.insert(*provider_id, extract_ts(record));
|
||||
|
||||
@@ -142,7 +142,7 @@ async fn process_series_info(
|
||||
return result;
|
||||
};
|
||||
|
||||
let _file_lock = app_config.file_locks.read_lock(&info_path);
|
||||
let _file_lock = app_config.file_locks.read_lock(&info_path).await;
|
||||
|
||||
// Contains the Series Info with episode listing
|
||||
let Ok(mut info_reader) = IndexedDocumentReader::<u32, String>::new(&info_path, &idx_path) else { return result; };
|
||||
|
||||
@@ -148,7 +148,7 @@ pub async fn playlist_resolve_vod(app_config: &AppConfig, client: Arc<reqwest::C
|
||||
|
||||
for pli in vod_info_iter {
|
||||
if let Some(provider_id) = pli.header.get_provider_id() {
|
||||
if let Some(content) = xtream_get_input_info(app_config, fpl.input, provider_id, XtreamCluster::Video) {
|
||||
if let Some(content) = xtream_get_input_info(app_config, fpl.input, provider_id, XtreamCluster::Video).await {
|
||||
// Add the "info" section to the playlist item additional properties.
|
||||
pli.header.additional_properties = from_str::<Map<String, Value>>(&content).ok().and_then(|info_doc| {
|
||||
info_doc.get("info").cloned().map(|info_content| {
|
||||
|
||||
Reference in New Issue
Block a user