use crate::response::CT_TEXT_HTML;
use axum::body::Body;
use axum::http::Response;
use axum::response::IntoResponse;
pub struct GetHomeResponse(Vec<u8>);
impl GetHomeResponse {
pub fn new(inner: Vec<u8>) -> Self {
Self(inner)
}
}
impl From<Vec<u8>> for GetHomeResponse {
fn from(inner: Vec<u8>) -> Self {
Self(inner)
}
}
impl IntoResponse for GetHomeResponse {
fn into_response(self) -> Response<Body> {
([CT_TEXT_HTML], self.0).into_response()
}
}