Avoid Warning: array_keys() expects parameter 1 to be array, boolean given. see #15458
git-svn-id: https://develop.svn.wordpress.org/trunk@18905 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
237d132595
commit
3932ffbff8
@ -682,7 +682,10 @@ function get_blogs_of_user( $id, $all = false ) {
|
||||
}
|
||||
|
||||
if ( false === $blogs ) {
|
||||
$userkeys = array_keys( get_user_meta( (int) $id ) );
|
||||
$userkeys = get_user_meta( (int) $id );
|
||||
if ( empty( $userkeys ) )
|
||||
return false;
|
||||
$userkeys = array_keys( $userkeys );
|
||||
if ( empty( $userkeys ) )
|
||||
return false;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user