Problem/Motivation

Upgrade status report: 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 media_directories_ui/src/Form/DirectoryDeleteForm.php:131

Steps to reproduce

Scan with Upgrade Status module.

Proposed resolution

Add explicit access check.

Remaining tasks

Provide issue fork/patch.

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

codebymikey created an issue. See original summary.

codebymikey’s picture

Status: Active » Needs review
StatusFileSize
new802 bytes
ytsurk’s picture

Status: Needs review » Needs work

Hi - thank you for the hint and MR.

I would turn the accessCheck to FALSE, as we test just before if the user has delete access.
IMO a term could be deleted when having only delete permission, but no view permission?

codebymikey’s picture

Status: Needs work » Needs review
StatusFileSize
new803 bytes

That makes sense, I've updated the MR.

ytsurk’s picture

Status: Needs review » Fixed

Thank you for your contribution!

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.

vitor faria’s picture

This does not seem to have been merged in the latest beta release available: 2.1.0-beta2.

Has this been merged in any release that is D10 compatible?

ytsurk’s picture

Sorry - I just released beta3.