use getter

This commit is contained in:
Thomas Pressnell 2021-07-12 16:32:06 +01:00
parent fae35237de
commit 5598feda6d
1 changed files with 1 additions and 1 deletions

View File

@ -408,7 +408,7 @@ function Server (options) {
if (req.protocolOp === Protocol.LDAP_REQ_BIND && res.status === 0) {
// 0 length == anonymous bind
if (req.dn.rdns.length === 0 && req.credentials === '') {
if (req.dn.length === 0 && req.credentials === '') {
conn.ldap.bindDN = new DN([new dn.RDN({ cn: 'anonymous' })])
} else {
conn.ldap.bindDN = req.dn