Making WordPress.org


Ignore:
Timestamp:
02/24/2016 06:44:33 AM (11 years ago)
Author:
dd32
Message:

Plugins Directory: Split get_or_create_plugin_post() into get_plugin_post() and create_plugin_post().
See #1584

File:
1 edited

Legend:

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

    r2556 r2561  
    150150        static function get_plugin_icon( $plugin, $output = 'raw' ) {
    151151                global $wporg_plugin_directory;
    152                 $plugin = $wporg_plugin_directory->get_or_create_plugin_post( $plugin );
    153                 if ( is_wp_error( $plugin ) ) {
     152                $plugin = $wporg_plugin_directory->get_plugin_post( $plugin );
     153                if ( ! $plugin ) {
    154154                        return false;
    155155                }
    … …  
    219219        static function get_plugin_banner( $plugin, $output = 'raw' ) {
    220220                global $wporg_plugin_directory;
    221                 $plugin = $wporg_plugin_directory->get_or_create_plugin_post( $plugin );
    222                 if ( is_wp_error( $plugin ) ) {
     221                $plugin = $wporg_plugin_directory->get_plugin_post( $plugin );
     222                if ( ! $plugin ) {
    223223                        return false;
    224224                }
Note: See TracChangeset for help on using the changeset viewer.