Use the new PermissionChecker service

Created on 25 October 2023, over 1 year ago
Updated 30 October 2023, over 1 year ago

Problem/Motivation

Permission check is now handled by the PermissionChecker service. Use this instead of $account->hasPermission.

At some point the old way will be deprecated by core.

Proposed resolution

Inject service where permissions are check and us it. See https://www.drupal.org/node/3348054 .

API changes

Some classes will receive the new PermissionChecker service as DI.

🐛 Bug report
Status

Needs work

Version

2.0

Component

Code

Created by

🇪🇸Spain tunic Madrid

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

Comments & Activities

Production build 0.71.5 2024