Changeset 12550
- Timestamp:
- 04/20/2023 08:26:26 PM (2 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/wordpress.org/public_html/wp-content/plugins/photo-directory/inc/admin.php
r12201 r12550 35 35 add_action( 'admin_notices', [ __CLASS__, 'add_notice_to_photo_media_if_pending' ] ); 36 36 add_filter( 'add_menu_classes', [ __CLASS__, 'add_admin_menu_pending_indicator' ] ); 37 add_filter( "manage_taxonomies_for_{$post_type}_columns", [ __CLASS__, 'remove_orientations_column' ], 10, 2 ); 37 38 38 39 // Record and display photo contributor IP address. … … 1053 1054 } 1054 1055 1056 /** 1057 * Removes the 'Orientations' column from post listings. 1058 * 1059 * The column doesn't represent information that needs to be gleaned from a 1060 * post listing overview. 1061 * 1062 * @param string[] $taxonomies Array of taxonomy names to show columns for. 1063 * @param string $post_type The post type. 1064 * @return string[] 1065 */ 1066 public static function remove_orientations_column( $taxonomies, $post_type ) { 1067 if ( Registrations::get_post_type() === $post_type ) { 1068 unset( $taxonomies[ Registrations::get_taxonomy( 'orientations' ) ] ); 1069 } 1070 1071 return $taxonomies; 1072 } 1073 1055 1074 } 1056 1075
Note: See TracChangeset
for help on using the changeset viewer.