mirror of
https://forgejo.ellis.link/continuwuation/continuwuity.git
synced 2025-09-10 07:32:49 +02:00
fix(appservice): Create user on authentication for existing appservices
Ensures appservice users are created during authentication requests, fixing the issue for appservices registered before the initial fix. This allows existing appservices to work without re-registration.
This commit is contained in:
parent
15ee7559ea
commit
3e68b67562
1 changed files with 4 additions and 0 deletions
|
@ -220,6 +220,10 @@ async fn auth_appservice(
|
|||
return Err!(Request(Exclusive("User is not in namespace.")));
|
||||
}
|
||||
|
||||
if !services.users.exists(&user_id).await {
|
||||
services.users.create(&user_id, None)?;
|
||||
}
|
||||
|
||||
Ok(Auth {
|
||||
origin: None,
|
||||
sender_user: Some(user_id),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue