Wont show password if only LDAP/AD enabled (#23860) (#24735)

Automatic Merge
This commit is contained in:
Emil-Carlsson 2023-11-03 12:22:22 +01:00 committed by GitHub
parent 04e7b6bc9e
commit 19eeccceb5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -146,6 +146,7 @@ const Login = ({onCustomizeHeader}: LoginProps) => {
const enableBaseLogin = enableSignInWithEmail || enableSignInWithUsername || ldapEnabled;
const enableExternalSignup = enableSignUpWithGitLab || enableSignUpWithOffice365 || enableSignUpWithGoogle || enableSignUpWithOpenId || enableSignUpWithSaml;
const showSignup = enableOpenServer && (enableExternalSignup || enableSignUpWithEmail || enableLdap);
const onlyLdapEnabled = enableLdap && !(enableSaml || enableSignInWithEmail || enableSignInWithUsername || enableSignUpWithEmail || enableSignUpWithGitLab || enableSignUpWithGoogle || enableSignUpWithOffice365 || enableSignUpWithOpenId);
const query = new URLSearchParams(search);
const redirectTo = query.get('redirect_to');
@ -740,7 +741,7 @@ const Login = ({onCustomizeHeader}: LoginProps) => {
};
const getResetPasswordLink = () => {
if (!PasswordEnableForgotLink || PasswordEnableForgotLink === 'false') {
if (!PasswordEnableForgotLink || PasswordEnableForgotLink === 'false' || onlyLdapEnabled) {
return null;
}