rust-lib/src/axum/traits.rs
Martin Berg Alstad 80f4af9087
Some checks failed
Build & test / build (push) Failing after 6s
Moved more code from hotel_service to lib
2024-09-08 17:27:20 +02:00

8 lines
180 B
Rust

use axum::body::Body;
use axum::http::Request;
use serde::Serialize;
pub trait BuildJson {
fn json<T: Serialize>(self, body: T) -> Result<Request<Body>, axum::http::Error>;
}