Updated: Comment #0

Problem/Motivation

https://api.drupal.org/api/drupal/core%21modules%21field%21field.depreca...

Under 'Deprecated' the wrong function is indicated as the Drupal 8 replacement.

"as of Drupal 8.0. Use Field::fieldInfo()->getBundleInstance($entity_type, $bundle, $field_name)."

(this function doesn't exist)

should be

"as of Drupal 8.0. Use Field::fieldInfo()->getInstance($entity_type, $bundle_name, $field_name)."

Proposed resolution

Patch to update the text.

CommentFileSizeAuthor
#1 doco-update-2071479-1.patch719 bytespameeela
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

pameeela’s picture

Status: Active » Needs review
FileSize
719 bytes

Patch attached.

larowlan’s picture

Status: Needs review » Reviewed & tested by the community

Assuming bot agrees

yched’s picture

Indeed, RTBC +1.
Thanks !

yched’s picture

Title: Incorrect function listed in doco at function field_info_instance » Incorrect replacement documented for @deprecated field_info_instance

typo

alexpott’s picture

Status: Reviewed & tested by the community » Fixed

Committed a04c933 and pushed to 8.x. Thanks!

Status: Fixed » Closed (fixed)

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