From b1dca57a1ce59bacc4089761275e4366e9760313 Mon Sep 17 00:00:00 2001 From: Robin Appelman Date: Fri, 23 Apr 2021 17:29:34 +0200 Subject: load share settings from the share manager in more places Signed-off-by: Robin Appelman --- apps/files/list.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'apps/files/list.php') diff --git a/apps/files/list.php b/apps/files/list.php index 52d736516c9..308d149c873 100644 --- a/apps/files/list.php +++ b/apps/files/list.php @@ -22,10 +22,14 @@ * */ +use OCP\Share\IManager; + $config = \OC::$server->getConfig(); $userSession = \OC::$server->getUserSession(); // TODO: move this to the generated config.js -$publicUploadEnabled = $config->getAppValue('core', 'shareapi_allow_public_upload', 'yes'); +/** @var IManager $shareManager */ +$shareManager = \OC::$server->get(IManager::class); +$publicUploadEnabled = $shareManager->shareApiLinkAllowPublicUpload() ? 'yes' : 'no';; $showgridview = $config->getUserValue($userSession->getUser()->getUID(), 'files', 'show_grid', false); $isIE = OC_Util::isIe(); -- cgit v1.2.3