Function choices::warp::reply::with_status [−][src]
pub fn with_status<T>(reply: T, status: StatusCode) -> WithStatus<T> where
T: Reply,
Wrap an impl Reply
to change its StatusCode
.
Example
use warp::Filter; let route = warp::any() .map(warp::reply) .map(|reply| { warp::reply::with_status(reply, warp::http::StatusCode::CREATED) });