X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=src%2FModule%2FBaseAdmin.php;h=f36389293c7113003999fc85a73729f832baa7e9;hb=8b02c285472ea28002cf9c8924e2885dd207ccd8;hp=89357d3a2ac5b61947f2569d8c4961b7ee799f96;hpb=d3e167c77c6245d7b0c4ec28908b992d27bde186;p=friendica.git diff --git a/src/Module/BaseAdmin.php b/src/Module/BaseAdmin.php index 89357d3a2a..f36389293c 100644 --- a/src/Module/BaseAdmin.php +++ b/src/Module/BaseAdmin.php @@ -1,6 +1,6 @@ getLocalUserId()) { if ($interactive) { DI::sysmsg()->addNotice(DI::l10n()->t('Please login to continue.')); DI::session()->set('return_path', DI::args()->getQueryString()); @@ -64,7 +63,7 @@ abstract class BaseAdmin extends BaseModule throw new HTTPException\ForbiddenException(DI::l10n()->t('You don\'t have access to administration pages.')); } - if (!empty($_SESSION['submanage'])) { + if (DI::userSession()->getSubManagedUserId()) { throw new HTTPException\ForbiddenException(DI::l10n()->t('Submanaged account can\'t access the administration pages. Please log back in as the main account.')); } } @@ -90,7 +89,6 @@ abstract class BaseAdmin extends BaseModule 'configuration' => [DI::l10n()->t('Configuration'), [ 'site' => ['admin/site' , DI::l10n()->t('Site') , 'site'], 'storage' => ['admin/storage' , DI::l10n()->t('Storage') , 'storage'], - 'users' => ['admin/users' , DI::l10n()->t('Users') , 'users'], 'addons' => ['admin/addons' , DI::l10n()->t('Addons') , 'addons'], 'themes' => ['admin/themes' , DI::l10n()->t('Themes') , 'themes'], 'features' => ['admin/features' , DI::l10n()->t('Additional features') , 'features'], @@ -101,11 +99,6 @@ abstract class BaseAdmin extends BaseModule 'deferred' => ['admin/queue/deferred', DI::l10n()->t('Inspect Deferred Workers'), 'deferred'], 'workerqueue' => ['admin/queue' , DI::l10n()->t('Inspect worker Queue') , 'workerqueue'], ]], - 'tools' => [DI::l10n()->t('Tools'), [ - 'contactblock' => ['admin/blocklist/contact', DI::l10n()->t('Contact Blocklist') , 'contactblock'], - 'blocklist' => ['admin/blocklist/server' , DI::l10n()->t('Server Blocklist') , 'blocklist'], - 'deleteitem' => ['admin/item/delete' , DI::l10n()->t('Delete Item') , 'deleteitem'], - ]], 'logs' => [DI::l10n()->t('Logs'), [ 'logsconfig' => ['admin/logs/', DI::l10n()->t('Logs') , 'logs'], 'logsview' => ['admin/logs/view' , DI::l10n()->t('View Logs') , 'viewlogs'], @@ -114,7 +107,6 @@ abstract class BaseAdmin extends BaseModule 'phpinfo' => ['admin/phpinfo' , DI::l10n()->t('PHP Info') , 'phpinfo'], 'probe' => ['probe' , DI::l10n()->t('probe address') , 'probe'], 'webfinger' => ['webfinger' , DI::l10n()->t('check webfinger') , 'webfinger'], - 'itemsource' => ['admin/item/source' , DI::l10n()->t('Item Source') , 'itemsource'], 'babel' => ['babel' , DI::l10n()->t('Babel') , 'babel'], 'debug/ap' => ['debug/ap' , DI::l10n()->t('ActivityPub Conversion') , 'debug/ap'], ]],