Changeset 3328
- Timestamp:
- 06/11/2016 08:43:06 AM (9 years ago)
- Location:
- sites/trunk/wordpress.org/public_html/wp-content/plugins/plugin-directory/cli
- Files:
-
- 1 added
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/wordpress.org/public_html/wp-content/plugins/plugin-directory/cli/class-import.php
r3213 r3328 79 79 } 80 80 81 if ( ! $plugin ) { 81 if ( ! $plugin ) { 82 82 $plugin = Plugin_Directory::create_plugin_post( array( 83 83 'slug' => $plugin_slug, … … 131 131 wp_update_post( $plugin ); 132 132 remove_filter( 'wp_insert_post_data', array( $this, 'filter_wp_insert_post_data' ) ); 133 134 // Set categories if there aren't any yet. wp-admin takes precedent. 135 if ( ! wp_get_post_terms( $plugin->ID, 'plugin_category', array( 'fields' => 'ids' ) ) ) { 136 wp_set_post_terms( $plugin->ID, Tag_To_Category::map( $readme->tags ), 'plugin_category' ); 137 } 133 138 134 139 foreach ( $this->readme_fields as $readme_field ) {
Note: See TracChangeset
for help on using the changeset viewer.