Code Duplication    Length = 4-4 lines in 2 locations

src/engine/ldap.php 2 locations

@@ 154-157 (lines=4) @@
151
    {
152
        debug_write_log(DEBUG_ERROR, '[ldap_finduser] ldap_start_tls() error: ' . ldap_err2str(ldap_errno($link)));
153
    }
154
    elseif (!@ldap_bind($link, LDAP_USERNAME, LDAP_PASSWORD))
155
    {
156
        debug_write_log(DEBUG_WARNING, '[ldap_finduser] ldap_bind(anonymous) error: ' . ldap_err2str(ldap_errno($link)));
157
    }
158
    else
159
    {
160
        $attrs  = array('dn', LDAP_ATTR_FULLNAME, LDAP_ATTR_EMAIL);
@@ 245-248 (lines=4) @@
242
    {
243
        debug_write_log(DEBUG_ERROR, '[ldap_finduser] ldap_start_tls() error: ' . ldap_err2str(ldap_errno($link)));
244
    }
245
    elseif (!@ldap_bind($link, LDAP_USERNAME, LDAP_PASSWORD))
246
    {
247
        debug_write_log(DEBUG_WARNING, '[ldap_findallusers] ldap_bind(anonymous) error: ' . ldap_err2str(ldap_errno($link)));
248
    }
249
    else
250
    {
251
        $attrs  = array(LDAP_ATTR_LOGIN, LDAP_ATTR_FULLNAME, LDAP_ATTR_EMAIL);