mirror of
https://git.asonix.dog/asonix/relay.git
synced 2024-11-22 01:21:06 +00:00
Add custom response status for not subscribed
This commit is contained in:
parent
19a6a6e61c
commit
cdef00f844
1 changed files with 1 additions and 0 deletions
|
@ -85,6 +85,7 @@ impl ResponseError for MyError {
|
|||
| MyError::Whitelist(_)
|
||||
| MyError::WrongActor(_)
|
||||
| MyError::BadActor(_, _) => StatusCode::FORBIDDEN,
|
||||
MyError::NotSubscribed(_) => StatusCode::UNAUTHORIZED,
|
||||
MyError::Duplicate => StatusCode::ACCEPTED,
|
||||
MyError::Kind(_) => StatusCode::BAD_REQUEST,
|
||||
_ => StatusCode::INTERNAL_SERVER_ERROR,
|
||||
|
|
Loading…
Reference in a new issue