mirror of
https://github.com/nextcloud/server.git
synced 2026-05-28 04:32:30 -04:00
Fixes hex2bin() in LDAP
Untangles the two if-else clauses into a more readable format. Signed-off-by: Morris Jobke <hey@morrisjobke.de>
This commit is contained in:
parent
fc30e7a6c6
commit
defac0ff0d
1 changed files with 7 additions and 5 deletions
|
|
@ -1253,11 +1253,13 @@ class Access extends LDAPUtility implements IUserTools {
|
|||
unset($item[$key]['count']);
|
||||
}
|
||||
if($key !== 'dn') {
|
||||
$selection[$i][$key] = $this->resemblesDN($key) ?
|
||||
$this->helper->sanitizeDN($item[$key])
|
||||
: $key === 'objectguid' || $key === 'guid' ?
|
||||
$selection[$i][$key] = $this->convertObjectGUID2Str($item[$key])
|
||||
: $item[$key];
|
||||
if($this->resemblesDN($key)) {
|
||||
$selection[$i][$key] = $this->helper->sanitizeDN($item[$key]);
|
||||
} else if($key === 'objectguid' || $key === 'guid') {
|
||||
$selection[$i][$key] = [$this->convertObjectGUID2Str($item[$key][0])];
|
||||
} else {
|
||||
$selection[$i][$key] = $item[$key];
|
||||
}
|
||||
} else {
|
||||
$selection[$i][$key] = [$this->helper->sanitizeDN($item[$key])];
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue