WordPress.org

Make WordPress Core

Opened 5 years ago

Closed 4 years ago

#36862 closed defect (bug) (fixed)

Inccorrect @since tags in WP_Plugins_List_Table::single_row()

Reported by: tfrommen Owned by: johnbillion
Milestone: 4.7 Priority: normal
Severity: normal Version: 4.4
Component: Plugins Keywords: has-patch commit
Focuses: docs Cc:

Description

For the (network_admin_)plugin_action_links_{$plugin_file} filters, the individual @since tag indicating the introduction of the filters is incorrect. The old $prefix included a trailing underscore. In case of the network_admin_* filters, also the version is incorrect (see the according/general plugin_* filters).

Attachments (2)

36862.patch (1.9 KB) - added by tfrommen 5 years ago.
36862.2.patch (2.0 KB) - added by SergeyBiryukov 4 years ago.

Download all attachments as: .zip

Change History (13)

@tfrommen
5 years ago

#1 @tfrommen
5 years ago

  • Keywords has-patch added

#2 in reply to: ↑ description @SergeyBiryukov
4 years ago

  • Milestone changed from Awaiting Review to 4.7

Some history:

  • plugin_action_links was introduced in [7517] (2.5.0).
  • The $context parameter was added [8049] (2.6.0).
  • plugin_action_links_$plugin_file was added in [9124] (2.7.0).
  • network_admin_* versions were added in [17004] (3.1.0).
  • Current docs were added in [34786] (4.4.0).

Replying to tfrommen:

In case of the network_admin_* filters, also the version is incorrect (see the according/general plugin_* filters).

I think the version is correct, as those were introduced in [17004].

I'm not sure the "As hook_name" notation is needed here. We use that for renamed hooks, but these ones were not renamed, just explicitly written out. Using it for the last two hooks is also incorrect, because they were introduced without $prefix.

36862.2.patch is my take on the corrections.

Last edited 4 years ago by SergeyBiryukov (previous) (diff)

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


4 years ago

#4 @stevenkword
4 years ago

@DrewAPicture Would you mind putting some eyes on this?

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


4 years ago

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


4 years ago

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


4 years ago

#8 @DrewAPicture
4 years ago

  • Keywords 2nd-opinion added

I think I'd be interested in @johnbillion's take here, since he introduced the docs. I do agree that the underscore wasn't there before so if we keep the initial introduce changelog entries, that at least should be fixed.

#9 @johnbillion
4 years ago

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

#10 @johnbillion
4 years ago

  • Keywords commit added; 2nd-opinion removed

I agree with Sergey, there's actually no need for the @since docs to be split into the prefix and post-prefix entries as the change was actually just to remove the dynamic portion of the hook name. The name itself didn't change.

#11 @johnbillion
4 years ago

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

Fixed in [39063].

Note: See TracTickets for help on using tickets.