mirror of
https://github.com/nextcloud/server.git
synced 2026-06-09 00:32:29 -04:00
Remove modern PHP syntax, and apply codesniffer fixes in Share20/Manager.php
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
This commit is contained in:
parent
0ee5c61eae
commit
1fb72e8277
1 changed files with 1 additions and 3 deletions
|
|
@ -82,7 +82,6 @@ use Symfony\Component\EventDispatcher\GenericEvent;
|
|||
* This class is the communication hub for all sharing related operations.
|
||||
*/
|
||||
class Manager implements IManager {
|
||||
|
||||
/** @var IProviderFactory */
|
||||
private $factory;
|
||||
/** @var ILogger */
|
||||
|
|
@ -669,7 +668,6 @@ class Manager implements IManager {
|
|||
* @param IShare $share
|
||||
*/
|
||||
protected function setLinkParent(IShare $share) {
|
||||
|
||||
// No sense in checking if the method is not there.
|
||||
if (method_exists($share, 'setParent')) {
|
||||
$storage = $share->getNode()->getStorage();
|
||||
|
|
@ -1534,7 +1532,7 @@ class Manager implements IManager {
|
|||
$uids = array_unique([$share->getShareOwner(),$share->getSharedBy()]);
|
||||
foreach ($uids as $uid) {
|
||||
$user = $this->userManager->get($uid);
|
||||
if ($user?->isEnabled() === false) {
|
||||
if (($user !== null) && ($user->isEnabled() === false)) {
|
||||
throw new ShareNotFound($this->l->t('The requested share comes from a disabled user'));
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue