Changeset 10897 for sites/trunk/wordpress.org/public_html/wp-content/plugins/plugin-directory/widgets/class-contributors.php
- Timestamp:
- 04/14/2021 02:25:44 AM (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/wordpress.org/public_html/wp-content/plugins/plugin-directory/widgets/class-contributors.php
r10883 r10897 49 49 50 50 // If no contributors were explicitly or properly listed, default to associated author. 51 if ( ! $contributors ) {52 $contributors = [ get_user_by( 'ID', $post->post_author )];51 if ( ! $contributors && ( $author = get_user_by( 'ID', $post->post_author ) ) ) { 52 $contributors = [ $author ]; 53 53 } 54 54
Note: See TracChangeset
for help on using the changeset viewer.