X-Git-Url: https://reisub.nsupdate.info/git/?a=blobdiff_plain;f=mod%2Fdelegate.php;h=280498db61a5c59d1948de191deaede28730bf4a;hb=458981f75cff2427976c9abc787eadf8e9e6267f;hp=c8987ab570c95c6c2ab719a1017f712f736417df;hpb=ea4e772b1e776876c40e30c67f30e6c35cf7d3aa;p=friendica.git%2F.git diff --git a/mod/delegate.php b/mod/delegate.php index c8987ab570..280498db61 100644 --- a/mod/delegate.php +++ b/mod/delegate.php @@ -27,7 +27,7 @@ function delegate_post(App $a) return; } - if (count($a->user) && x($a->user, 'uid') && $a->user['uid'] != local_user()) { + if (count($a->user) && !empty($a->user['uid']) && $a->user['uid'] != local_user()) { notice(L10n::t('Permission denied.') . EOL); return; } @@ -63,7 +63,7 @@ function delegate_content(App $a) if ($a->argc > 2 && $a->argv[1] === 'add' && intval($a->argv[2])) { // delegated admins can view but not change delegation permissions - if (x($_SESSION, 'submanage')) { + if (!empty($_SESSION['submanage'])) { $a->internalRedirect('delegate'); } @@ -84,7 +84,7 @@ function delegate_content(App $a) if ($a->argc > 2 && $a->argv[1] === 'remove' && intval($a->argv[2])) { // delegated admins can view but not change delegation permissions - if (x($_SESSION, 'submanage')) { + if (!empty($_SESSION['submanage'])) { $a->internalRedirect('delegate'); }