The code in LinkFormatter::prepareView() is strictly value per value, does not benefit from the "multiple entities" aspect of prepareView().

What's being done here could totally be inlined in viewElements() - however, it is also used by LinkSeparateFormatter, which extends LinkFormatter. So it should be moved to a protected helper method, called for each item in viewElements() in both classes.

CommentFileSizeAuthor
#1 LinkFormatter-prepareView-2047753-1.patch4.76 KByched
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

yched’s picture

Status: Active » Needs review
FileSize
4.76 KB

Patch

effulgentsia’s picture

Status: Needs review » Reviewed & tested by the community

Makes complete sense.

alexpott’s picture

Status: Reviewed & tested by the community » Fixed

Committed c35607f and pushed to 8.x. Thanks!

Status: Fixed » Closed (fixed)

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

Anonymous’s picture

Issue summary: View changes

typo