Skip to content

Commit

Permalink
Issue #6117: Fix contact form permissions for admin role on settings …
Browse files Browse the repository at this point in the history
  • Loading branch information
kiamlaluno authored and quicksketch committed Sep 22, 2023
1 parent 067ebd5 commit b5c8502
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions core/modules/contact/contact.admin.inc
Expand Up @@ -141,9 +141,8 @@ function contact_form_permissions() {
'#description' => theme('user_permission_description', array('permission_item' => $perm_item)),
);
foreach ($roles as $role_name => $role) {
// Builds arrays for checked boxes for each role. Always select the Admin
// role on new forms.
if (in_array($perm, $role->permissions) || ($role->name == $admin_role)) {
// Builds arrays for checked boxes for each role.
if (in_array($perm, $role->permissions)) {
$status[$role_name][] = $perm;
}
}
Expand Down

1 comment on commit b5c8502

@backdrop-ci
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.