Skip to content

Commit

Permalink
fix ldap_search(): Argument #1 ($ldap) must be of type LDAP|array, st…
Browse files Browse the repository at this point in the history
…ring given
  • Loading branch information
ralfbecker committed Aug 13, 2024
1 parent 702b3e9 commit b75f850
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion api/src/Accounts/Ldap.php
Original file line number Diff line number Diff line change
Expand Up @@ -1099,7 +1099,7 @@ function name2id($_name,$which='account_lid',$account_type=null)
{
$attr = $which == 'account_lid' ? 'cn' : static::MAIL_ATTR;

if (($data = ldap_search($this->group_context, '(&('.$attr.'=' . $name . ")(objectclass=posixgroup)$this->group_filter)", ['gidNumber'])) &&
if (($data = $this->_ldap_search($this->group_context, '(&('.$attr.'=' . $name . ")(objectclass=posixgroup)$this->group_filter)", ['gidNumber'])) &&
!empty($data['gidnumber'][0]))
{
return -$data['gidnumber'][0];
Expand Down

0 comments on commit b75f850

Please sign in to comment.