WordPress.org

Make WordPress Core

Opened 11 months ago

Closed 11 months ago

Last modified 11 months ago

#37142 closed defect (bug) (fixed)

Incorrectly documented datatype for $request parameter of posts_request filter.

Reported by: coffee2code Owned by: DrewAPicture
Milestone: 4.6 Priority: normal
Severity: trivial Version:
Component: General Keywords: has-patch
Focuses: docs Cc:

Description

The @param docblock for the $request parameter (which represents the "complete SQL query") of the posts_request filter indicates that the parameter has a datatype of array. However, two lines of code earlier it is clearly set as a string.

Patch attached.

Attachments (1)

37142.diff (544 bytes) - added by coffee2code 11 months ago.
Patch referenced in ticket.

Download all attachments as: .zip

Change History (3)

@coffee2code
11 months ago

Patch referenced in ticket.

#1 @DrewAPicture
11 months ago

  • Owner set to DrewAPicture
  • Resolution set to fixed
  • Status changed from new to closed

In 37848:

Docs: Correct the $request parameter datatype in the hook doc for the posts_request filter.

It's a string, not an array.

Props coffee2code.
Fixes #37142.

#2 @DrewAPicture
11 months ago

  • Milestone changed from Awaiting Review to 4.6
Note: See TracTickets for help on using tickets.