In the \core\includes\entity.inc file the docblock contains code examples with syntax errors for the $values variables for the entity_get_display and entity_get_form_display functions, which are gonna be deprecated.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

balagan created an issue. See original summary.

balagan’s picture

balagan’s picture

Assigned: balagan » Unassigned
Status: Active » Needs review

Version: 8.2.x-dev » 8.3.x-dev

Drupal 8.2.0-beta1 was released on August 3, 2016, which means new developments and disruptive changes should now be targeted against the 8.3.x-dev branch. For more information see the Drupal 8 minor version schedule and the Allowed changes during the Drupal 8 release cycle.

michielnugter’s picture

Status: Needs review » Reviewed & tested by the community

I found out the same problem and came up with the exact same patch. Looks good, set to RTBC.

Status: Reviewed & tested by the community » Needs work

The last submitted patch, 2: 2755545-2.patch, failed testing.

michielnugter’s picture

Status: Needs work » Needs review
FileSize
0 bytes
681 bytes

Reroll on the current 8.3.x branch, removed 1 change as it was already fixed in another issue.

michielnugter’s picture

FileSize
354 bytes

Reroll on the current 8.3.x branch, removed 1 change as it was already fixed in another issue.

balagan’s picture

Status: Needs review » Reviewed & tested by the community

Patch looks fine, changing it to RTBC.

  • xjm committed 4f8869c on 8.3.x
    Issue #2755545 by michielnugter, balagan: Docblock shows wrong code to...

  • xjm committed f084a9e on 8.2.x
    Issue #2755545 by michielnugter, balagan: Docblock shows wrong code to...
xjm’s picture

Version: 8.3.x-dev » 8.2.x-dev
Status: Reviewed & tested by the community » Fixed
Related issues: +#2474151: Mark procedural wrappers in entity.inc as deprecated, +#2547933: Code example for non deprecated use of entity_get_display is wrong

I checked with git blame and this was added in #2474151: Mark procedural wrappers in entity.inc as deprecated and has not changed since. The similar docs for the entity_view_display were updated in #2547933: Code example for non deprecated use of entity_get_display is wrong but that issue missed this one.

Committed and pushed to 8.3.x and 8.2.x. Thanks!

Status: Fixed » Closed (fixed)

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