Problem/Motivation
After upgrading from 4.08 to 4.0.14, "Configure" link is displayed even if user does not have the appropriate permission.
Steps to reproduce
- Install environment_indicator 4.0.14.
- Give authenticated role the 'access environment indicator' but not the 'administer environment indicator settings' permissions.
- Give authenticated role the permission to use the toolbar.
- Login as authenticated user
- Click the environment indicator in the toolbar an you should see the "Configure" link.
- Click "Configure link" and get "Access Denied".
Proposed resolution
Do not render "Configure" link in the toolbar if the role does not have "administer environment indicator settings" permissions.
Remaining tasks
User interface changes
API changes
Data model changes
Issue fork environment_indicator-3342457
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #4
peacog commentedCreated a MR that solves this.
Comment #5
devkinetic commentedThis looks good!
Comment #8
isholgueras commentedThanks for the patch
Comment #9
isholgueras commented