Making WordPress.org


Ignore:
Timestamp:
06/02/2016 12:27:31 PM (10 years ago)
Author:
ocean90
Message:

Plugin Directory: In the developers shortcode skip users which don't exist.

Avoids a PHP notice when using the WordPress Meta Environment.

See #1719.

File:
1 edited

Legend:

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

    r3253 r3292  
    2323                foreach ( $contributors as $contributor_slug ) {
    2424                        $contributor = get_user_by( 'login', $contributor_slug );
     25                        if ( ! $contributor ) {
     26                                continue;
     27                        }
    2528
    2629                        $output .= '<li>' . get_avatar( $contributor->ID, 32 ) . utf8_encode( $contributor->display_name ) . '</li>';
Note: See TracChangeset for help on using the changeset viewer.