Changeset 5148
- Timestamp:
- 03/13/2017 04:00:59 PM (8 years ago)
- Location:
- sites/trunk/wordpress.org/public_html/wp-content/plugins/wporg-cli
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/wordpress.org/public_html/wp-content/plugins/wporg-cli/inc/class-handbook.php
r4802 r5148 8 8 * Append a "Edit on GitHub" link to Handbook document titles 9 9 */ 10 public static function filter_the_title_edit_link( $title ) {10 public static function filter_the_title_edit_link( $title, $id = null ) { 11 11 // Only apply to the main title for the document 12 12 if ( ! is_singular( 'handbook' ) 13 13 || ! is_main_query() 14 14 || ! in_the_loop() 15 || get_the_ID()!== get_queried_object_id() ) {15 || $id !== get_queried_object_id() ) { 16 16 return $title; 17 17 } -
sites/trunk/wordpress.org/public_html/wp-content/plugins/wporg-cli/wporg-cli.php
r4786 r5148 21 21 add_action( 'save_post', array( 'WPOrg_Cli\Markdown_Import', 'action_save_post' ) ); 22 22 add_filter( 'cron_schedules', array( 'WPOrg_Cli\Markdown_Import', 'filter_cron_schedules' ) ); 23 add_filter( 'the_title', array( 'WPOrg_Cli\Handbook', 'filter_the_title_edit_link' ) );23 add_filter( 'the_title', array( 'WPOrg_Cli\Handbook', 'filter_the_title_edit_link' ), 10, 2 ); 24 24 add_filter( 'get_edit_post_link', array( 'WPOrg_Cli\Handbook', 'redirect_edit_link_to_github' ), 10, 3 ); 25 25 add_filter( 'o2_filter_post_actions', array( 'WPOrg_Cli\Handbook', 'redirect_o2_edit_link_to_github' ), 11, 2 );
Note: See TracChangeset
for help on using the changeset viewer.