Skip to content

Strapi is not honoring the settings when reading the permissions #18997

@robsonpiere

Description

@robsonpiere

Bug report

Required System information

  • Node.js version: v18.18
  • NPM version: 9.8.1 yarn/1.22.19
  • Strapi version: 4.5.15
  • Database: postgres 15
  • Operating system: Linux / ubuntu and alpine
  • Is your project Javascript or Typescript: Typescript

Describe the bug

When you remove the permission to update a field for the Editor profile, this change is not saved in the database after refersh. When you return to the application, you can see that the permission is maintained, both in production and in development.

Steps to reproduce the behavior

  1. Go to the settings menu -> administrative panel -> roles
  2. Select the editor profile
  3. Choose a content type (in my example article) and remove the update permission from a field (slug in my example)
  4. When you save, it will appear that the change has been made, but the bank has not changed the configuration and when you reload the page (or run strapi develop) again you will see that the change has not taken effect.

Expected behavior

When you save, it will appear that the change has been made, but the bank has not changed the configuration and when you reload the page (or run yarn develop) again you will see that the change has not taken effect.

Screenshots

Remove permission:

image

After running strapi develop again (in development) or update the page in production:

image

Code snippets

N/A

Additional context

N/A

Metadata

Metadata

Assignees

No one assigned

    Labels

    issue: bugIssue reporting a bugseverity: mediumIf it breaks the basic use of the product but can be worked aroundsource: core:adminSource is core/admin packagestatus: confirmedConfirmed by a Strapi Team member or multiple community membersstatus: duplicateIs a duplicate of another issueversion: 4Issue is present in Strapi v4

    Type

    No type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions