Make WordPress Core

Opened 5 years ago

Closed 5 years ago

#49180 closed defect (bug) (fixed)

Wrong documentation for register_post_status() parameters

Reported by: audrasjb's profile audrasjb Owned by: sergeybiryukov's profile SergeyBiryukov
Milestone: 5.4 Priority: normal
Severity: normal Version:
Component: Posts, Post Types Keywords: has-patch
Focuses: docs Cc:

Description

I think I found some documentation mistakes in register_post_status() parameters.
https://developer.wordpress.org/reference/functions/register_post_status/

  • show_in_admin_all_list: Default is value of $internal.

Looks like it's the opposite:
https://core.trac.wordpress.org/browser/tags/5.3/src/wp-includes/post.php#L1087

  • show_in_admin_status_list : Default is value of $internal.

Looks like it's the opposite as well:
https://core.trac.wordpress.org/browser/tags/5.3/src/wp-includes/post.php#L1091

Attachments (1)

49180.diff (1.4 KB) - added by audrasjb 5 years ago.
Docs: Correct @param description for register_post_status()

Download all attachments as: .zip

Change History (5)

@audrasjb
5 years ago

Docs: Correct @param description for register_post_status()

#1 @audrasjb
5 years ago

  • Keywords has-patch added; needs-patch removed

In 49180.diff:

  • Docs: Correct @param description for register_post_status()

#2 @SergeyBiryukov
5 years ago

  • Milestone changed from Awaiting Review to 5.4
  • Owner set to SergeyBiryukov
  • Status changed from new to reviewing

#3 @SergeyBiryukov
5 years ago

Introduced in [29090], appears to be a copy/paste of $exclude_from_search.

#4 @SergeyBiryukov
5 years ago

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

In 47066:

Docs: Correct description for show_in_admin_all_list and show_in_admin_status_list arguments of register_post_status().

Props audrasjb.
Fixes #49180.

Note: See TracTickets for help on using tickets.