Make WordPress Core

Opened 19 months ago

Closed 18 months ago

Last modified 18 months ago

#58972 closed defect (bug) (fixed)

Doc block on function reference for page_template_dropdown is incorrect

Reported by: maxinacube's profile maxinacube Owned by: audrasjb's profile audrasjb
Milestone: 6.4 Priority: normal
Severity: minor Version: 4.7
Component: Text Changes Keywords: has-patch
Focuses: docs Cc:

Description

Within the doc block for the page_template_dropdown function in wp-admin/includes/template.php it states that the default value for $post_type is "post" while the parameter on the function sets the default the value for $post_type to "page".

Attachments (1)

58972.diff (771 bytes) - added by dhruvishah2203 18 months ago.

Download all attachments as: .zip

Change History (8)

This ticket was mentioned in PR #4962 on WordPress/wordpress-develop by maxinacube.


19 months ago
#1

  • Keywords has-patch added

The doc block for the page_template_dropdown function lists the default $post_type as "post", while the parameter on the function is sets the default $post_type to "page".

This PR reflects the proper default value of $post_type in the doc block.

Trac ticket: https://core.trac.wordpress.org/ticket/58972

#2 @audrasjb
19 months ago

  • Owner set to audrasjb
  • Status changed from new to reviewing

This ticket was mentioned in Slack in #core by priethor. View the logs.


18 months ago

#4 @johnbillion
18 months ago

  • Version changed from trunk to 4.7

#5 @SergeyBiryukov
18 months ago

  • Milestone changed from Awaiting Review to 6.4

Hi there, thanks for the ticket and the PR! Introduced in [38951] / #18375.

#6 @audrasjb
18 months ago

  • Resolution set to fixed
  • Status changed from reviewing to closed

In 56441:

Docs: Correct default post type in page_template_dropdown() docblock.

The default post type used by page_template_dropdown() is page, not post.

Props maxinacube.
Fixes #58972.
See #58833.

@audrasjb commented on PR #4962:


18 months ago
#7

committed in 56441

Note: See TracTickets for help on using tickets.