@@ -56,14 +56,13 @@ fn alias_redirect(uri: &Uri, https: bool, host: &str, external_port: u16) -> war
5656}
5757
5858// static file reply
59- #[ instrument( skip( uri, host, domain_storage, origin_opt) ) ]
60- async fn file_resp < A : http_body:: Body , B : http_body:: Body > (
59+ async fn file_resp < A : http_body:: Body > (
6160 req : & Request < A > ,
6261 uri : & Uri ,
6362 host : & str ,
6463 domain_storage : Arc < DomainStorage > ,
6564 origin_opt : Option < Validated > ,
66- ) -> Result < Response < B > , Infallible > {
65+ ) -> Result < warp :: reply :: Response , Infallible > {
6766 let path = uri. path ( ) ;
6867 let mut resp = match get_cache_file ( path, host, domain_storage. clone ( ) ) . await {
6968 Some ( item) => {
@@ -117,7 +116,6 @@ fn get_authority<B:http_body::Body>(req: &Request<B>) -> Option<Authority> {
117116 } )
118117}
119118
120- #[ instrument( skip( service_config, domain_storage, challenge_path, external_port) ) ]
121119pub async fn create_http_service < B : http_body:: Body > (
122120 req : Request < B > ,
123121 service_config : Arc < ServiceConfig > ,
@@ -180,7 +178,6 @@ pub async fn create_http_service<B:http_body::Body>(
180178 }
181179}
182180
183- #[ instrument( skip( service_config, domain_storage, external_port) ) ]
184181pub async fn create_https_service < B : http_body:: Body > (
185182 req : Request < B > ,
186183 service_config : Arc < ServiceConfig > ,
@@ -214,19 +211,19 @@ pub async fn create_https_service<B:http_body::Body>(
214211 }
215212}
216213
217- pub fn not_found < B : http_body:: Body > ( ) -> Response < B > {
214+ pub fn not_found < B : http_body:: Body > ( ) -> warp :: reply :: Response {
218215 let mut resp = Response :: default ( ) ;
219216 * resp. status_mut ( ) = StatusCode :: NOT_FOUND ;
220217 resp
221218}
222- pub fn forbid < B : http_body :: Body > ( ) -> Response < B > {
219+ pub fn forbid ( ) -> warp :: reply :: Response {
223220 let mut resp = Response :: default ( ) ;
224221 * resp. status_mut ( ) = StatusCode :: FORBIDDEN ;
225222 resp
226223}
227224
228225pub fn resp ( code : StatusCode , str : & ' static str ) -> warp:: reply:: Response {
229- let mut response = str. into_response ( ) ;
226+ let mut resp = str. into_response ( ) ;
230227 * resp. status_mut ( ) = code;
231228 resp
232229}
0 commit comments