Making WordPress.org

Changeset 4346


Ignore:
Timestamp:
11/11/2016 04:47:32 AM (7 years ago)
Author:
dd32
Message:

Plugin Directory: Stop importing dates from bbPress, except on initial plugin-import (to be removed).
It looks like this might be causing a bug where stale data from bbPress gets pulled over to WordPress on occasion.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/plugins/plugin-directory/cli/class-import.php

    r4214 r4346  
    9898            ) );
    9999        }
     100        $plugin->post_status = $status;
    100101
    101102        $readme = $data['readme'];
     
    119120        $plugin->post_excerpt = trim( $readme->short_description ) ?: $headers->Description ?: $plugin->post_excerpt;
    120121
    121         $plugin->post_date     = $topic->topic_start_time;
    122         $plugin->post_date_gmt = $topic->topic_start_time;
    123         $plugin->override_modified_date = true;
    124         $plugin->post_modified     = $topic->topic_time;
    125         $plugin->post_modified_gmt = $topic->topic_time;
    126 
    127         $plugin->post_status = $status;
    128         if ( ! $plugin->post_title ) {
    129             $plugin->post_title = $topic->topic_title;
    130         }
    131 
    132122        // Bump last updated if the version has changed.
    133123        if ( !isset( $headers->Version ) || $headers->Version != get_post_meta( $plugin->ID, 'version', true ) ) {
     124            $plugin->override_modified_date = true;
    134125            $plugin->post_modified = $plugin->post_modified_gmt = current_time( 'mysql' );
    135126        }
     
    192183        // Finally, set the new version live.
    193184        update_post_meta( $plugin->ID, 'stable_tag', $stable_tag );
     185
     186        return true;
    194187    }
    195188
Note: See TracChangeset for help on using the changeset viewer.