From 66ab91564b0a518800b579d9c2e1e9d01da7d6a0 Mon Sep 17 00:00:00 2001 From: Ryan Boren Date: Mon, 20 Apr 2009 20:03:20 +0000 Subject: [PATCH] Cast to array to fix warning. Props johnkolbert, Denis-de-Bernardy. fixes #9128 git-svn-id: https://develop.svn.wordpress.org/trunk@11019 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-includes/capabilities.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/wp-includes/capabilities.php b/wp-includes/capabilities.php index a40d0a5801..cccd68daba 100644 --- a/wp-includes/capabilities.php +++ b/wp-includes/capabilities.php @@ -534,9 +534,9 @@ class WP_User { $this->allcaps = array(); foreach ( (array) $this->roles as $role ) { $role =& $wp_roles->get_role( $role ); - $this->allcaps = array_merge( $this->allcaps, $role->capabilities ); + $this->allcaps = array_merge( (array) $this->allcaps, (array) $role->capabilities ); } - $this->allcaps = array_merge( $this->allcaps, $this->caps ); + $this->allcaps = array_merge( (array) $this->allcaps, (array) $this->caps ); } /**