fix permissions

master
Jean-Christian Paul Denis 2022-12-03 16:59:27 +01:00
parent ab1b4ab8c8
commit fe6c9a520b
Signed by: JcDenis
GPG Key ID: 1B5B8C5B90B6C951
2 changed files with 4 additions and 2 deletions

View File

@ -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;
}

View File

@ -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',