Use of deprecated entity_delete_multiple on user delete

Created on 11 March 2021, about 4 years ago
Updated 19 March 2025, 17 days ago

Problem/Motivation

Deleting a user account calls _quiz_delete_users_results which uses entity_delete_multiple() function. This function has been removed from D9.

Steps to reproduce

Behavior is a non-fatal error upon user account deletion

Proposed resolution

Replace entity_delete_multiple() with process shown here https://api.drupal.org/api/drupal/core%21includes%21entity.inc/function/...

$controller = \Drupal::entityTypeManager()->getStorage('quiz_result');
$entities = $controller->loadMultiple($result_ids);
$controller->delete($entities);

πŸ› Bug report
Status

Fixed

Version

6.0

Component

Code - Quiz core

Created by

πŸ‡ΊπŸ‡ΈUnited States Chris Dart

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

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024