mirror of
https://github.com/nextcloud/server.git
synced 2026-06-08 08:16:43 -04:00
Merge pull request #27703 from nextcloud/backport/27698/stable21
[stable21] LDAP: determine shares of offline users only when needed
This commit is contained in:
commit
b614af016a
1 changed files with 3 additions and 7 deletions
|
|
@ -146,7 +146,8 @@ class OfflineUser {
|
|||
*/
|
||||
public function getDN() {
|
||||
if (!isset($this->dn)) {
|
||||
$this->fetchDetails();
|
||||
$dn = $this->mapping->getDNByName($this->ocName);
|
||||
$this->dn = ($dn !== false) ? $dn : '';
|
||||
}
|
||||
return $this->dn;
|
||||
}
|
||||
|
|
@ -212,7 +213,7 @@ class OfflineUser {
|
|||
*/
|
||||
public function getHasActiveShares() {
|
||||
if (!isset($this->hasActiveShares)) {
|
||||
$this->fetchDetails();
|
||||
$this->determineShares();
|
||||
}
|
||||
return $this->hasActiveShares;
|
||||
}
|
||||
|
|
@ -232,11 +233,6 @@ class OfflineUser {
|
|||
foreach ($properties as $property => $app) {
|
||||
$this->$property = $this->config->getUserValue($this->ocName, $app, $property, '');
|
||||
}
|
||||
|
||||
$dn = $this->mapping->getDNByName($this->ocName);
|
||||
$this->dn = ($dn !== false) ? $dn : '';
|
||||
|
||||
$this->determineShares();
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Reference in a new issue