From: Hypolite Petovan Date: Fri, 13 Dec 2019 18:29:06 +0000 (-0500) Subject: Return early if user.uid isn't present in ACL::getFullSelectorHTML X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=fe5b80b9ba09adf82616d08dc090f36dea62c81d;p=friendica.git Return early if user.uid isn't present in ACL::getFullSelectorHTML - Addresses https://github.com/friendica/friendica/issues/7675#issuecomment-565533824 --- diff --git a/src/Core/ACL.php b/src/Core/ACL.php index 83fae423ac..64e03d4719 100644 --- a/src/Core/ACL.php +++ b/src/Core/ACL.php @@ -335,6 +335,10 @@ class ACL extends BaseObject */ public static function getFullSelectorHTML(Page $page, array $user = null, bool $for_federation = false, array $default_permissions = []) { + if (empty($user['uid'])) { + return ''; + } + $page->registerFooterScript(Theme::getPathForFile('asset/typeahead.js/dist/typeahead.bundle.js')); $page->registerFooterScript(Theme::getPathForFile('js/friendica-tagsinput/friendica-tagsinput.js')); $page->registerStylesheet(Theme::getPathForFile('js/friendica-tagsinput/friendica-tagsinput.css'));