fix TestFetchMessagesFromNonExistentRoom complement test
Signed-off-by: June Clementine Strawberry <june@3.dog>
This commit is contained in:
parent
931fd4c802
commit
ecea0cff69
1 changed files with 5 additions and 1 deletions
|
@ -1,6 +1,6 @@
|
||||||
use axum::extract::State;
|
use axum::extract::State;
|
||||||
use conduwuit::{
|
use conduwuit::{
|
||||||
Event, PduCount, PduEvent, Result, at,
|
Err, Event, PduCount, PduEvent, Result, at,
|
||||||
utils::{
|
utils::{
|
||||||
IterStream, ReadyExt,
|
IterStream, ReadyExt,
|
||||||
result::{FlatOk, LogErr},
|
result::{FlatOk, LogErr},
|
||||||
|
@ -68,6 +68,10 @@ pub(crate) async fn get_message_events_route(
|
||||||
let room_id = &body.room_id;
|
let room_id = &body.room_id;
|
||||||
let filter = &body.filter;
|
let filter = &body.filter;
|
||||||
|
|
||||||
|
if !services.rooms.metadata.exists(room_id).await {
|
||||||
|
return Err!(Request(Forbidden("Room does not exist to this server")));
|
||||||
|
}
|
||||||
|
|
||||||
let from: PduCount = body
|
let from: PduCount = body
|
||||||
.from
|
.from
|
||||||
.as_deref()
|
.as_deref()
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue