Resolve access check errors for D10 compatibility

Created on 1 February 2023, almost 2 years ago
Updated 2 August 2024, 4 months ago

Problem/Motivation

While working on upgrades to Drupal 10 Upgrade status provided these errors as needing to be resolved manually:

On Line 123 of web/modules/contrib/admin_toolbar/admin_toolbar_search/src/SearchLinks.php

Relying on entity queries to check access by default is deprecated in drupal:9.2.0 and an error will be thrown from drupal:10.0.0. Call \Drupal\Core\Entity\Query\QueryInterface::accessCheck() with TRUE or FALSE to specify whether access should be checked.

On Line 114 of web/modules/contrib/admin_toolbar/admin_toolbar_tools/src/Plugin/Derivative/ExtraLinks.php

Relying on entity queries to check access by default is deprecated in drupal:9.2.0 and an error will be thrown from drupal:10.0.0. Call \Drupal\Core\Entity\Query\QueryInterface::accessCheck() with TRUE or FALSE to specify whether access should be checked.

Proposed resolution

Call \Drupal\Core\Entity\Query\QueryInterface::accessCheck() with TRUE

Remaining tasks

Call \Drupal\Core\Entity\Query\QueryInterface::accessCheck() with TRUE

๐Ÿ“Œ Task
Status

Closed: outdated

Version

3.4

Component

Code

Created by

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