Access check is not set

Created on 30 October 2023, about 1 year ago

Problem/Motivation

Any code, that relies upon openy_mappings.location_repository service, for example Daxko: https://git.drupalcode.org/project/daxko/-/blob/1.0.x/src/DaxkoDataWrapp... in Drupal 10 will experience the following error:

Entity queries must explicitly set whether the query should be access checked or not. See Drupal\Core\Entity\Query\QueryInterface::accessCheck().

Steps to reproduce

1. Install Latest Open Y distro
2. Install the aforementioned Daxko module: drupal.org/project/daxko
3. Execute drush ev '\Drupal::service("daxko.data_wrapper")->populateDaxkoMembershipTypes();'

Proposed resolution

Include accessCheck(FALSE) to all of the queries as we don't need to check the user access.

User interface changes

No changes.

API changes

No changes.

πŸ› Bug report
Status

Fixed

Version

1.0

Component

Code

Created by

πŸ‡ΊπŸ‡¦Ukraine Sardis

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

Comments & Activities

Production build 0.71.5 2024