$role, 'result' => $ret]; Hook::call('get_role_perms', $x); return $x['result']; } /** * @brief Array with translated role names and grouping. * * Return an associative array with grouped role names that can be used * to create select groups like in \e field_select_grouped.tpl. * * @return array */ public static function roles(): array { $roles = [ t('Social Networking') => [ 'social' => t('Social - Normal'), 'social_restricted' => t('Social - Restricted') ], t('Community Group') => [ 'forum' => t('Group - Normal'), 'forum_limited' => t('Group - Limited'), 'forum_moderated' => t('Group - Moderated'), 'forum_restricted' => t('Group - Restricted'), ], ]; Hook::call('list_permission_roles', $roles); return $roles; } }