feat: Allow self-service deactivation to be disabled

This commit is contained in:
Ginger committed 2026-06-29 09:35:50 -04:00
1 parent daaf09cb26
commit 91afbd122f
6 files changed
+42 -1

No files matched your search

+7
View File
@@ -285,6 +285,13 @@ pub(crate) async fn deactivate_route(
let sender_user = identity.expect_sender_user()?;
if !services.config.allow_deactivation {
return Err!(Request(Unauthorized(
"You may not deactivate your own account. Contact your server's administrator for \
assistance."
)));
}
// Prompt the user to confirm with their password using UIAA
let _ = services
.uiaa