WordPress.org

Making WordPress.org

Ticket #1400: 1400.diff

File 1400.diff, 635 bytes (added by akirk, 4 years ago)
  • wporg-routes/routes/wp-plugins.php

     
    8080                        }
    8181                } );
    8282
    83                 $project->icon = wporg_get_plugin_icon( $project->slug, 64 );
     83                if ( function_exists( 'wporg_get_plugin_icon' ) ) {
     84                        $project->icon = wporg_get_plugin_icon( $project->slug, 64 );
     85                } else {
     86                        $project->icon = '<div class="default-icon"><span class="dashicons dashicons-admin-plugins"></span></div>`';
     87                }
    8488
    8589                $this->tmpl( 'projects-wp-plugins', get_defined_vars() );
    8690        }