replace ErrorKind::Forbidden
with forbidden()
non-exhaustive constructor
917584e0ca
Signed-off-by: strawberry <strawberry@puppygock.gay>
This commit is contained in:
parent
13cd9c4c38
commit
ddcf43f1b8
21 changed files with 75 additions and 73 deletions
|
@ -94,7 +94,7 @@ impl Service {
|
|||
event ID {event_id}"
|
||||
);
|
||||
return Err(Error::BadRequest(
|
||||
ErrorKind::Forbidden,
|
||||
ErrorKind::forbidden(),
|
||||
"Federation of this room is currently disabled on this server.",
|
||||
));
|
||||
}
|
||||
|
@ -163,7 +163,7 @@ impl Service {
|
|||
event ID {event_id}"
|
||||
);
|
||||
return Err(Error::BadRequest(
|
||||
ErrorKind::Forbidden,
|
||||
ErrorKind::forbidden(),
|
||||
"Federation of this room is currently disabled on this server.",
|
||||
));
|
||||
}
|
||||
|
@ -1645,7 +1645,7 @@ impl Service {
|
|||
Ok(())
|
||||
} else {
|
||||
info!("Server {} was denied by room ACL in {}", server_name, room_id);
|
||||
Err(Error::BadRequest(ErrorKind::Forbidden, "Server was denied by room ACL"))
|
||||
Err(Error::BadRequest(ErrorKind::forbidden(), "Server was denied by room ACL"))
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue