WordPress.org

Make WordPress Core

Opened 6 years ago

Closed 6 years ago

#25357 closed defect (bug) (fixed)

Hook Docs: wp-admin/includes/class-wp-plugin-install-list-table.php

Reported by: naomicbush Owned by: kpdesign
Milestone: 3.7 Priority: normal
Severity: normal Version:
Component: Inline Docs Keywords: has-patch commit
Focuses: Cc:

Description

Attached patch has docs for the filters

install_plugins_tabs
install_plugins_nonmenu_tabs
install_plugins_table_api_args_$tab
plugin_install_action_links

and actions

install_plugins_table_header

in wp-admin/includes/class-wp-plugin-install-list-table.php.

Attachments (3)

wp-admin-includes-class-wp-plugin-install-list-table.25357.diff (2.3 KB) - added by naomicbush 6 years ago.
25357.diff (2.3 KB) - added by naomicbush 6 years ago.
Using the correct patch naming convention
25357.2.diff (2.4 KB) - added by naomicbush 6 years ago.
Revisions per DrewAPicture

Download all attachments as: .zip

Change History (10)

#1 @DrewAPicture
6 years ago

  • Keywords needs-patch reporter-feedback added; has-patch removed

@naomicbush: It looks like you maybe forgot to attach your patch.

#2 @naomicbush
6 years ago

  • Keywords has-patch added; needs-patch removed

Sorry about that — I thought I needed to create the ticket first. Patch attached.

@naomicbush
6 years ago

Using the correct patch naming convention

#3 @DrewAPicture
6 years ago

  • Keywords needs-patch added; reporter-feedback has-patch removed
  • Milestone changed from Awaiting Review to 3.7

Hi Naomi, thanks for the patch :)

Some notes on 25357.diff:

  • install_plugins_tabs filter: "Filter the tabs that are shown on the page." needs to be more specific. It's best to document hooks as if they are independent of each other. So maybe, "Filter the tabs that are shown on the Plugin Install screen." For the @param description, maybe "An array of tabs used on the Plugin Install screen." or something
  • install_plugins_nonmenu_tabs filter: "Filter the $nonmenu_tabs." isn't very helpful information. Perhaps something like "Filter tabs not associated with a menu item." Same for the @param description. I know it's copied from the function, but it's kind of vague and unhelpful. Try to be clear and direct.
  • install_plugins_table_api_args_$tabs filter: "Plugin API" should be "Plugin Installer API", "the $tab." should be "each tab."
  • install_plugins_table_header action: Again, think of all hooks as independent of each other, so you need to provide context in the description. "Fires before table header" should be "Fires before Plugin Install table header"
  • plugin_install_action_links filter: "the plugin." should be generalized to "a plugin."
Last edited 6 years ago by DrewAPicture (previous) (diff)

#4 @DrewAPicture
6 years ago

  • Milestone changed from 3.7 to Awaiting Review
  • Owner set to kpdesign
  • Status changed from new to reviewing

@naomicbush
6 years ago

Revisions per DrewAPicture

#5 @naomicbush
6 years ago

Thanks, DrewAPicture, for the clarification :-) Patch revised.

#6 @kpdesign
6 years ago

  • Keywords has-patch commit added; needs-patch removed
  • Milestone changed from Awaiting Review to 3.7
  • Status changed from reviewing to accepted

Naomi, the patch looks good. :) Recommend commit.

#7 @DrewAPicture
6 years ago

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

In 25630:

Inline documentation for hooks in wp-admin/includes/class-wp-plugin-install-list-table.php.

Props naomicbush.
Fixes #25357.

Note: See TracTickets for help on using tickets.