Problem/Motivation

Properly deprecate entity_load_multiple and ENTITY_TYPE_load_multiple().

Proposed resolution

Clean up deprecations to be of the format proposed in #3024461: Adopt consistent deprecation format for core and contrib deprecation messages
Add @trigger_error()

Remaining tasks

User interface changes

None

API changes

None

Data model changes

None

Release notes snippet

N/a

CommentFileSizeAuthor
#5 3028657-5.patch15.99 KBalexpott
#5 3-5-interdiff.txt13.35 KBalexpott
#3 3028657-3.patch7.27 KBalexpott

Comments

alexpott created an issue. See original summary.

alexpott’s picture

alexpott’s picture

Status: Active » Needs review
StatusFileSize
new7.27 KB

Removed all the other @see's because these are not useful as this method is deprecated.

berdir’s picture

+++ b/core/includes/entity.inc
@@ -179,22 +179,13 @@ function entity_revision_delete($entity_type, $revision_id) {
  *
- * @deprecated in Drupal 8.0.x, will be removed before Drupal 9.0.0. Use
- *   The method overriding Entity::loadMultiple() for the entity type, e.g.
- *   \Drupal\node\Entity\Node::loadMultiple() if the entity type is known. If
- *   the entity type is variable, use the entity manager service to load the
- *   entity from the entity storage:
- *   @code
- *     \Drupal::entityTypeManager()->getStorage($entity_type)->loadMultiple($id);
- *   @endcode
+ * @deprecated in Drupal 8.0.x, will be removed before Drupal 9.0.0. Use the
+ *   entity type storage's loadMultiple() method.
  *

We are losing some useful information here, but it was also pretty long and if people need more information then they can find that in the new change record reference.

This doesn't seem to follow what is apparently the new standard for the revision reference, though (drupal:8.0.0)?

Do we need legacy tests for these functions?

alexpott’s picture

StatusFileSize
new13.35 KB
new15.99 KB

All the *_load_multiple() functions are now deprecated the same way and tested.

Re losing the useful information - it's not that useful (a) it's on the CR (b) it is the code in the function anyways.

andypost’s picture

Status: Needs review » Reviewed & tested by the community

Looks polished & has tests

catch’s picture

Status: Reviewed & tested by the community » Fixed

Committed 447cdb7 and pushed to 8.7.x. Thanks!

  • catch committed 447cdb7 on 8.7.x
    Issue #3028657 by alexpott, Berdir: Properly deprecate...

Status: Fixed » Closed (fixed)

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