fix: appservice masquerading requirement check

This commit is contained in:
31a05b9c authored and Ellis Git committed 2026-07-04 18:21:51 +00:00
1 parent 7fac885a98
commit 6aab456466
1 file changed
+3 -2
+3 -2
View File
@@ -60,8 +60,9 @@ impl ClientIdentity {
pub(crate) fn expect_sender_device(&self) -> Result<&DeviceId> {
match self {
| Self::User { sender_device, .. } => Ok(sender_device),
| Self::Appservice { .. } =>
| Self::User { sender_device, .. }
| Self::Appservice { sender_device: Some(sender_device), .. } => Ok(sender_device),
| Self::Appservice { sender_device: None, .. } =>
Err!(Request(Forbidden("Appservices must masquerade to use this endpoint."))),
}
}