remove unusefull code
This commit is contained in:
parent
aa8963901a
commit
bab1d2accd
@ -22,7 +22,6 @@ class Backend extends dcNsProcess
|
|||||||
public static function init(): bool
|
public static function init(): bool
|
||||||
{
|
{
|
||||||
static::$init = defined('DC_CONTEXT_ADMIN')
|
static::$init = defined('DC_CONTEXT_ADMIN')
|
||||||
&& !is_null(dcCore::app()->auth) // nullsafe PHP < 8.0
|
|
||||||
&& dcCore::app()->auth->isSuperAdmin();
|
&& dcCore::app()->auth->isSuperAdmin();
|
||||||
|
|
||||||
return static::$init;
|
return static::$init;
|
||||||
|
@ -26,22 +26,12 @@ class BackendBehaviors
|
|||||||
# admin plugins page tab
|
# admin plugins page tab
|
||||||
public static function pluginsTabs(): void
|
public static function pluginsTabs(): void
|
||||||
{
|
{
|
||||||
// nullsafe PHP < 8.0
|
|
||||||
if (is_null(dcCore::app()->adminurl)) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
self::modulesToolsTabs(dcCore::app()->plugins, explode(',', DC_DISTRIB_PLUGINS), dcCore::app()->adminurl->get('admin.plugins'));
|
self::modulesToolsTabs(dcCore::app()->plugins, explode(',', DC_DISTRIB_PLUGINS), dcCore::app()->adminurl->get('admin.plugins'));
|
||||||
}
|
}
|
||||||
|
|
||||||
# admin themes page tab
|
# admin themes page tab
|
||||||
public static function themesTabs(): void
|
public static function themesTabs(): void
|
||||||
{
|
{
|
||||||
// nullsafe PHP < 8.0
|
|
||||||
if (is_null(dcCore::app()->adminurl)) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
self::modulesToolsTabs(dcCore::app()->themes, explode(',', DC_DISTRIB_THEMES), dcCore::app()->adminurl->get('admin.blog.theme'));
|
self::modulesToolsTabs(dcCore::app()->themes, explode(',', DC_DISTRIB_THEMES), dcCore::app()->adminurl->get('admin.blog.theme'));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user