diff --git a/_admin.php b/_admin.php index 3519c9f..7e7556a 100644 --- a/_admin.php +++ b/_admin.php @@ -14,7 +14,7 @@ if (!defined('DC_CONTEXT_ADMIN')) { return null; } -if (!dcCore::app()->auth->check(dcAuth::PERMISSION_ADMIN, dcCore::app()->blog->id)) { +if (!dcCore::app()->auth->check(dcCore::app()->auth->makePermissions([dcAuth::PERMISSION_ADMIN]), dcCore::app()->blog->id)) { return null; } diff --git a/_define.php b/_define.php index 943cb9c..64b8985 100644 --- a/_define.php +++ b/_define.php @@ -21,7 +21,9 @@ $this->registerModule( '2022.11.28', [ 'requires' => [['core', '2.24']], - 'permissions' => dcAuth::PERMISSION_ADMIN, + 'permissions' => dcCore::app()->auth->makePermissions([ + dcAuth::PERMISSION_ADMIN, + ]), 'type' => 'plugin', 'support' => 'https://github.com/JcDenis/postslistOptions', 'details' => 'https://plugins.dotaddict.org/dc2/details/postslistOptions',