Skip to main content

ruest_err

Macro ruest_err 

Source
macro_rules! ruest_err {
    (BadRequest, $msg:expr) => { ... };
    (NotFound, $msg:expr) => { ... };
    (Conflict, $msg:expr) => { ... };
    (Internal, $msg:expr) => { ... };
    (Unauthorized, $msg:expr) => { ... };
    (Forbidden, $msg:expr) => { ... };
}
Expand description

Erreur HTTP lisible : return Err(ruest_err!(BadRequest, "message"));