handled some warnings

This commit is contained in:
Simon
2025-10-03 17:34:16 +00:00
parent 20d069f01f
commit f9ccdd8b33
8 changed files with 50 additions and 61 deletions

View File

@@ -270,7 +270,7 @@ impl PmvhavenProvider {
}
};
let proxy = Proxy::all("http://192.168.0.103:8081").unwrap();
// let proxy = Proxy::all("http://192.168.0.103:8081").unwrap();
let client = Client::builder()
.cert_verification(false)
.emulation(Emulation::Firefox136)
@@ -300,34 +300,6 @@ impl PmvhavenProvider {
}
return Ok(video_items);
}
// else {
// let flare_url = env::var("FLARE_URL").expect("FLARE_URL not set");
// let flare = Flaresolverr::new(flare_url);
// let result = flare
// .solve(FlareSolverrRequest {
// cmd: "request.get".to_string(),
// url: url.clone(),
// maxTimeout: 60000,
// })
// .await;
// let video_items = match result {
// Ok(res) => {
// // println!("FlareSolverr response: {}", res);
// self.get_video_items_from_html(res.solution.response)
// }
// Err(e) => {
// println!("Error solving FlareSolverr: {}", e);
// return Err("Failed to solve FlareSolverr".into());
// }
// };
// if !video_items.is_empty() {
// cache.remove(&url);
// cache.insert(url.clone(), video_items.clone());
// } else {
// return Ok(old_items);
// }
// Ok(video_items)
// }
Err("Failed to get Videos".into())
}
async fn query(&self, cache: VideoCache, page: u8, query: &str) -> Result<Vec<VideoItem>> {
@@ -349,7 +321,7 @@ impl PmvhavenProvider {
}
};
let proxy = Proxy::all("http://192.168.0.103:8081").unwrap();
// let proxy = Proxy::all("http://192.168.0.103:8081").unwrap();
let client = Client::builder()
.cert_verification(false)
.emulation(Emulation::Firefox136)