refactor: Represent route auth information in the type system

This commit is contained in:
Ginger committed 2026-05-26 13:28:23 -04:00
1 parent 793d399477
commit 4b75d78ac4
78 files changed
+496 -482

No files matched your search

+1 -1
View File
@@ -15,7 +15,7 @@ pub(crate) async fn get_mutual_rooms_route(
State(services): State<crate::State>,
body: Ruma<mutual_rooms::unstable::Request>,
) -> Result<mutual_rooms::unstable::Response> {
let sender_user = body.sender_user();
let sender_user = body.identity.sender_user();
if sender_user == body.user_id {
return Err!(Request(Unknown("You cannot request rooms in common with yourself.")));