diff --git a/lib/private/share/share.php b/lib/private/share/share.php index 8899df2563..e62bdebc08 100644 --- a/lib/private/share/share.php +++ b/lib/private/share/share.php @@ -635,7 +635,7 @@ class Share extends Constants { throw new \Exception($message_t); } // verify that the user has share permission - if (!\OC\Files\Filesystem::isSharable($path)) { + if (!\OC\Files\Filesystem::isSharable($path) || \OCP\Util::isSharingDisabledForUser()) { $message = 'You are not allowed to share %s'; $message_t = $l->t('You are not allowed to share %s', [$path]); \OCP\Util::writeLog('OCP\Share', sprintf($message, $path), \OCP\Util::DEBUG);