Minor: Remove obsolete code that was originally added for PHP 5.3 compatibility
This commit is contained in:
parent
0784d3fff2
commit
bec5c00e89
|
|
@ -680,7 +680,7 @@ if ( !class_exists(UpdateChecker::class, false) ):
|
||||||
$status = $this->validateApiResponse($result);
|
$status = $this->validateApiResponse($result);
|
||||||
$metadata = null;
|
$metadata = null;
|
||||||
if ( !is_wp_error($status) ){
|
if ( !is_wp_error($status) ){
|
||||||
if ( version_compare(PHP_VERSION, '5.3', '>=') && (strpos($metaClass, '\\') === false) ) {
|
if ( (strpos($metaClass, '\\') === false) ) {
|
||||||
$metaClass = __NAMESPACE__ . '\\' . $metaClass;
|
$metaClass = __NAMESPACE__ . '\\' . $metaClass;
|
||||||
}
|
}
|
||||||
$metadata = call_user_func(array($metaClass, 'fromJson'), $result['body']);
|
$metadata = call_user_func(array($metaClass, 'fromJson'), $result['body']);
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue