Browse Source
Merge pull request #3740 from BlackDex/fix-ldap-import-org-status
Fix UserOrg status during LDAP Import
pull/3592/head
Daniel García
1 year ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with
1 additions and
1 deletions
-
src/api/core/public.rs
|
|
@ -85,7 +85,7 @@ async fn ldap_import(data: JsonUpcase<OrgImportData>, token: PublicToken, mut co |
|
|
|
new_user |
|
|
|
} |
|
|
|
}; |
|
|
|
let user_org_status = if CONFIG.mail_enabled() { |
|
|
|
let user_org_status = if CONFIG.mail_enabled() || user.password_hash.is_empty() { |
|
|
|
UserOrgStatus::Invited as i32 |
|
|
|
} else { |
|
|
|
UserOrgStatus::Accepted as i32 // Automatically mark user as accepted if no email invites
|
|
|
|