overhault to fix warnings etc

This commit is contained in:
Simon
2025-10-04 14:28:29 +00:00
parent d84cc715a8
commit 28a4c57616
29 changed files with 889 additions and 1338 deletions

View File

@@ -1,7 +1,10 @@
use crate::api::ClientVersion;
use crate::status::Channel;
use crate::DbPool;
use crate::providers::Provider;
use crate::util::cache::VideoCache;
use crate::videos::{ServerOptions, VideoItem};
use async_trait::async_trait;
use error_chain::error_chain;
use htmlentity::entity::{ICodedDataTrait, decode};
use std::vec;
@@ -17,6 +20,7 @@ error_chain! {
pub struct FreshpornoProvider {
url: String,
}
impl FreshpornoProvider {
pub fn new() -> Self {
FreshpornoProvider {
@@ -156,6 +160,7 @@ impl FreshpornoProvider {
}
#[async_trait]
impl Provider for FreshpornoProvider {
async fn get_videos(
&self,
@@ -187,4 +192,12 @@ impl Provider for FreshpornoProvider {
}
}
}
fn get_channel(&self,clientversion:ClientVersion) -> Channel {
println!("Getting channel for placeholder with client version: {:?}",clientversion);
let _ = clientversion;
Channel {
id:"placeholder".to_string(),name:"PLACEHOLDER".to_string(),description:"PLACEHOLDER FOR PARENT CLASS".to_string(),premium:false,favicon:"https://www.google.com/s2/favicons?sz=64&domain=missav.ws".to_string(),status:"active".to_string(),categories:vec![],options:vec![],nsfw:true,cacheDuration:None,
}
}
}