Merge pull request #19543 from owncloud/fix-19542

Check if decoded JSON returned null
This commit is contained in:
Thomas Müller 2015-10-03 12:20:33 +02:00
Родитель 99d7352ef9 8f4611e21d
Коммит 122141be92
1 изменённых файлов: 1 добавлений и 1 удалений

Просмотреть файл

@ -88,7 +88,7 @@ $excludeGroups = $appConfig->getValue('core', 'shareapi_exclude_groups', 'no') =
$template->assign('shareExcludeGroups', $excludeGroups); $template->assign('shareExcludeGroups', $excludeGroups);
$excludedGroupsList = $appConfig->getValue('core', 'shareapi_exclude_groups_list', ''); $excludedGroupsList = $appConfig->getValue('core', 'shareapi_exclude_groups_list', '');
$excludedGroupsList = json_decode($excludedGroupsList); $excludedGroupsList = json_decode($excludedGroupsList);
$template->assign('shareExcludedGroupsList', implode('|', $excludedGroupsList)); $template->assign('shareExcludedGroupsList', !is_null($excludedGroupsList) ? implode('|', $excludedGroupsList) : '');
$template->assign('encryptionEnabled', \OC::$server->getEncryptionManager()->isEnabled()); $template->assign('encryptionEnabled', \OC::$server->getEncryptionManager()->isEnabled());
$backends = \OC::$server->getUserManager()->getBackends(); $backends = \OC::$server->getUserManager()->getBackends();
$externalBackends = (count($backends) > 1) ? true : false; $externalBackends = (count($backends) > 1) ? true : false;