Check for string, as method may be an array. fixes #10778

git-svn-id: https://develop.svn.wordpress.org/trunk@13958 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Andrew Nacin 2010-04-03 07:18:16 +00:00
parent 066c4893a1
commit fdd1d24399
1 changed files with 1 additions and 1 deletions

View File

@ -356,7 +356,7 @@ EOD;
$args = $args[0];
}
// Are we dealing with a function or a method?
if (substr($method, 0, 5) == 'this:') {
if ( is_string( $method ) && substr($method, 0, 5) == 'this:' ) {
// It's a class method - check it exists
$method = substr($method, 5);
if (!method_exists($this, $method)) {