You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Aug 18, 2024. It is now read-only.
A user can be given a global permission to give them access to manage all groups in the website. This permission is called administer group, but there are a few problems with this permission:
It is confusing in the context of Organic Groups since it seems to imply the permission is only valid for a single group entity.
I had a look at why this is called as such and it is for historical reasons. OG originally had a bunch of permissions such as administer group users, administer group permissions and at some point a new global permission was added called administer organic groups (ref commit 44d6a32). Then it was renamed to administer group in a gigantic commit which had the intention back in 2010 to rename Organic Groups to Group (ref commit ec296b4). This plan was abandoned later on and the name "Organic Groups" was kept, but the permission wasn't changed back.
Let's call it "administer organic groups" again so we don't cause any conflicts with the Group module, but keep a B/C layer in place for people upgrading their sites from D7.
The text was updated successfully, but these errors were encountered:
I started on this but there is a small complication: in D7 the administer group permission is both a global (Drupal) permission and a group permission, and in the D8 code we have been using them interchangeably.
Here is the relevant section from the D7 module:
function og_permission() {
return array(
'administer group' => array(
'title' => t('Administer Organic groups permissions'),
'description' => t('Administer all groups and permissions.'),
),
);
}
function og_og_permission() {
// ...
$perms['administer group'] = array(
'title' => t('Administer group'),
'description' => t('Manage group members and content in the group.'),
'default role' => array(OG_ADMINISTRATOR_ROLE),
'restrict access' => TRUE,
);
// ...
}
I started to do a global search/replace operation to fix this, but we'll have to look at each individual case whether it is intended to be the group level permission or the global permission.
I suggest we keep the administer group group level permission, there is no conflict here, and it will help us to differentiate between both.
A user can be given a global permission to give them access to manage all groups in the website. This permission is called
administer group
, but there are a few problems with this permission:I had a look at why this is called as such and it is for historical reasons. OG originally had a bunch of permissions such as
administer group users
,administer group permissions
and at some point a new global permission was added calledadminister organic groups
(ref commit 44d6a32). Then it was renamed toadminister group
in a gigantic commit which had the intention back in 2010 to rename Organic Groups to Group (ref commit ec296b4). This plan was abandoned later on and the name "Organic Groups" was kept, but the permission wasn't changed back.Let's call it "administer organic groups" again so we don't cause any conflicts with the Group module, but keep a B/C layer in place for people upgrading their sites from D7.
The text was updated successfully, but these errors were encountered: