pimpbunny and more fixes
This commit is contained in:
11
src/proxy.rs
11
src/proxy.rs
@@ -15,6 +15,7 @@ use crate::proxies::sxyprn::SxyprnProxy;
|
||||
use crate::proxies::vjav::VjavProxy;
|
||||
use crate::proxies::vidara::VidaraProxy;
|
||||
use crate::proxies::lulustream::LulustreamProxy;
|
||||
use crate::proxies::thaiporntv::ThaipornTvProxy;
|
||||
use crate::proxies::*;
|
||||
use crate::util::requester::Requester;
|
||||
|
||||
@@ -125,11 +126,16 @@ pub fn config(cfg: &mut web::ServiceConfig) {
|
||||
.route(web::get().to(crate::proxies::porndishthumb::get_image)),
|
||||
);
|
||||
cfg.service(
|
||||
web::resource("/pornhub-thumb/{endpoint}*")
|
||||
web::resource("/proxy/pornhub-thumb/{endpoint}*")
|
||||
.route(web::post().to(crate::proxies::pornhubthumb::get_image))
|
||||
.route(web::get().to(crate::proxies::pornhubthumb::get_image)),
|
||||
);
|
||||
}
|
||||
cfg.service(
|
||||
web::resource("/proxy/thaiporntv/{tail:.*}")
|
||||
.route(web::post().to(proxy2redirect))
|
||||
.route(web::get().to(proxy2redirect)),
|
||||
);
|
||||
}
|
||||
|
||||
async fn proxy2redirect(
|
||||
req: HttpRequest,
|
||||
@@ -163,6 +169,7 @@ fn get_proxy(proxy: &str) -> Option<AnyProxy> {
|
||||
"porndish" => Some(AnyProxy::Porndish(PorndishProxy::new())),
|
||||
"spankbang" => Some(AnyProxy::Spankbang(SpankbangProxy::new())),
|
||||
"lulustream" => Some(AnyProxy::Lulustream(LulustreamProxy::new())),
|
||||
"thaiporntv" => Some(AnyProxy::ThaipornTv(ThaipornTvProxy::new())),
|
||||
_ => None,
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user