- Issue created by @mdeahmad
- last update
about 1 year ago 71 pass, 2 fail - Status changed to Needs review
about 1 year ago 9:58am 24 August 2023
The Workbench Moderation module currently relies on deprecated methods for checking access using entity queries. This practice will be deprecated in Drupal 9.2.0 and will result in an error starting from Drupal 10.0.0. The recommended approach is to use \Drupal\Core\Entity\Query\QueryInterface::accessCheck() with TRUE or FALSE to explicitly specify whether access should be checked.
Details:
In the file modules/contrib/workbench_moderation/src/EntityTypeInfo.php at line 239 and in the file modules/contrib/workbench_moderation/src/Form/ModerationStateTransitionForm.php at line 100, the Workbench Moderation module relies on entity queries to check access. However, this approach is being deprecated in Drupal 9.2.0 and will lead to errors in Drupal 10.0.0.
To address this issue, the Workbench Moderation module should be updated to use the new recommended approach. Specifically, it should utilize \Drupal\Core\Entity\Query\QueryInterface::accessCheck() with either TRUE or FALSE to clearly indicate whether access checks are required.
Proposed Patch:
I have added patch for that.
Needs review
1.7
Code