aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorCôme Chilliet <91878298+come-nc@users.noreply.github.com>2023-08-10 17:05:19 +0200
committerCôme Chilliet <91878298+come-nc@users.noreply.github.com>2023-08-28 09:40:12 +0200
commit24ad2e2dc41b265c527d38e791f9ff2989df1897 (patch)
treeeecf2ffa4c95b6390061daec4dab20038ba25231 /lib
parentfd0de0a2d1f3ced04451342ad8f3a2ad0e68eb8c (diff)
downloadnextcloud-server-24ad2e2dc41b265c527d38e791f9ff2989df1897.tar.gz
nextcloud-server-24ad2e2dc41b265c527d38e791f9ff2989df1897.zip
Use nullsafe call syntax instead of additionnal check
Co-authored-by: Benjamin Gaussorgues <benjamin.gaussorgues@nextcloud.com> Signed-off-by: Côme Chilliet <91878298+come-nc@users.noreply.github.com>
Diffstat (limited to 'lib')
-rw-r--r--lib/private/Share20/Manager.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/private/Share20/Manager.php b/lib/private/Share20/Manager.php
index 2e6b9ab840c..b03608f9872 100644
--- a/lib/private/Share20/Manager.php
+++ b/lib/private/Share20/Manager.php
@@ -1559,7 +1559,7 @@ class Manager implements IManager {
$uids = array_unique([$share->getShareOwner(),$share->getSharedBy()]);
foreach ($uids as $uid) {
$user = $this->userManager->get($uid);
- if (($user !== null) && !$user->isEnabled()) {
+ if ($user?->isEnabled() === false) {
throw new ShareNotFound($this->l->t('The requested share comes from a disabled user'));
}
}