Correctly handle HEAD requests (#129)

This commit is contained in:
David Pedersen
2021-08-15 20:27:13 +02:00
committed by GitHub
parent 9cd543401f
commit 995ffc1aa2
9 changed files with 184 additions and 22 deletions
+5 -1
View File
@@ -5,7 +5,10 @@ use crate::{
};
use bytes::Bytes;
use futures_util::future::Ready;
use http::{header::AUTHORIZATION, Request, Response, StatusCode, Uri};
use http::{
header::{HeaderMap, AUTHORIZATION},
Request, Response, StatusCode, Uri,
};
use hyper::{Body, Server};
use serde::Deserialize;
use serde_json::json;
@@ -18,6 +21,7 @@ use std::{
};
use tower::{make::Shared, service_fn, BoxError, Service};
mod get_to_head;
mod handle_error;
mod nest;
mod or;