diff --git a/packages/client/src/store/LdapFormStore.js b/packages/client/src/store/LdapFormStore.js index 27538a068f..c725630f72 100644 --- a/packages/client/src/store/LdapFormStore.js +++ b/packages/client/src/store/LdapFormStore.js @@ -14,7 +14,6 @@ import delay from "lodash/delay"; import { toastr } from "@docspace/shared/components/toast"; const constants = { - NULL_PERCENT: 0, SSL_LDAP_PORT: 636, DEFAULT_LDAP_PORT: 389, GET_STATUS_TIMEOUT: 1000, @@ -606,6 +605,15 @@ class LdapFormStore { setIsSslEnabled = (enabled) => { this.isSslEnabled = enabled; + + if ( + this.requiredSettings.portNumber == constants.DEFAULT_LDAP_PORT || + this.requiredSettings.portNumber == constants.SSL_LDAP_PORT + ) { + this.setPortNumber( + enabled ? constants.SSL_LDAP_PORT : constants.DEFAULT_LDAP_PORT, + ); + } }; get isCronEnabled() {