WordPress.org

Make WordPress Core

Ticket #38161: 38161.patch

File 38161.patch, 556 bytes (added by desmith, 4 years ago)

First stab at patch for 38161

Line 
1diff -ru /home/davsmi/wordpress/wp-includes/pluggable.php /var/www/html/tierone-test.wustl.edu/wp-includes/pluggable.php
2--- a/wp-includes/pluggable.php    2016-09-26 11:07:37.480348749 -0500
3+++ b/wp-includes/pluggable.php     
42016-09-26 10:53:24.425822719 -0500
5@@ -328,6 +328,11 @@
6                        $sitename = substr( $sitename, 4 );
7                }
8
9+               // If $_SERVER['SERVER_NAME'] is unset (i.e. called from wp-cli)
10+               if ( !isset( $sitename ) ) {
11+                       $sitename = substr( home_url( '', 'http'), 7);
12+               }
13+
14                $from_email = 'wordpress@' . $sitename;
15        }
16