Only show rebuild permission messages to users who can access link

Created on 26 July 2024, 5 months ago

Problem/Motivation

Messages warning users that permissions may need to be rebuilt can be shown to users who cannot access the permission rebuild page. This may cause confusion and frustrations to users.

Steps to reproduce

  1. Create a "User admin" role
  2. Give the User admin the "administer users" permission
  3. As a user with the role of "User admin", update any user's roles
  4. After saving the user you should see the "Your changes have been saved. You may have to rebuild permissions for your changes to take effect." message
  5. Clicking on the link to rebuild permissions gives you a 403 error

Proposed resolution

Check a user's permissions before adding the message.

Remaining tasks

Add permission check

User interface changes

Message will be hidden for users who cannot rebuild permissions.

API changes

None

Data model changes

None

πŸ› Bug report
Status

Active

Version

2.0

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States averagejoe3000 Swanzey, NH

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

Production build 0.71.5 2024