fix warning in r14342, see #13104
git-svn-id: https://develop.svn.wordpress.org/trunk@14351 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
6a1f093ed8
commit
3f36d28e3b
@ -89,8 +89,8 @@ function get_blog_details( $fields, $get_all = true ) {
|
||||
$blog = wp_cache_get($key, 'blog-lookup');
|
||||
if ( false !== $blog )
|
||||
return $blog;
|
||||
if ( substr( $domain, 0, 4 ) == 'www.' ) {
|
||||
$nowww = substr( $domain, 4 );
|
||||
if ( substr( $fields['domain'], 0, 4 ) == 'www.' ) {
|
||||
$nowww = substr( $fields['domain'], 4 );
|
||||
$blog = $wpdb->get_row( $wpdb->prepare( "SELECT * FROM $wpdb->blogs WHERE domain IN (%s,%s) AND path = %s ORDER BY CHAR_LENGTH(domain) DESC", $nowww, $fields['domain'], $fields['path'] ) );
|
||||
} else {
|
||||
$blog = $wpdb->get_row( $wpdb->prepare( "SELECT * FROM $wpdb->blogs WHERE domain = %s AND path = %s", $fields['domain'], $fields['path'] ) );
|
||||
|
Loading…
Reference in New Issue
Block a user