mirror of https://github.com/fafhrd91/actix-web
Merge branch 'master' of github.com:qrvaelet/actix-web
This commit is contained in:
commit
6da682ad1b
|
@ -627,6 +627,12 @@ pub fn ErrorPreconditionFailed<T>(err: T) -> InternalError<T> {
|
||||||
InternalError::new(err, StatusCode::PRECONDITION_FAILED)
|
InternalError::new(err, StatusCode::PRECONDITION_FAILED)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// Helper function that creates wrapper of any error and generate *RANGE NOT SATISFIABLE* response.
|
||||||
|
#[allow(non_snake_case)]
|
||||||
|
pub fn ErrorRangeNotSatisfiable<T>(err: T) -> InternalError<T> {
|
||||||
|
InternalError::new(err, StatusCode::RANGE_NOT_SATISFIABLE)
|
||||||
|
}
|
||||||
|
|
||||||
/// Helper function that creates wrapper of any error and generate *EXPECTATION FAILED* response.
|
/// Helper function that creates wrapper of any error and generate *EXPECTATION FAILED* response.
|
||||||
#[allow(non_snake_case)]
|
#[allow(non_snake_case)]
|
||||||
pub fn ErrorExpectationFailed<T>(err: T) -> InternalError<T> {
|
pub fn ErrorExpectationFailed<T>(err: T) -> InternalError<T> {
|
||||||
|
|
Loading…
Reference in New Issue