Skip to content
This repository was archived by the owner on Oct 2, 2019. It is now read-only.

Commit 276db36

Browse files
committed
Merge pull request zendframework#540 from mhujer/php7-fix-xml-rpc
Fix PHP 7 BC breaks in Zend_XmlRpc/Amf_Server
2 parents 7cbb1d5 + 17f179d commit 276db36

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

library/Zend/Amf/Server.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -767,9 +767,9 @@ public function setClass($class, $namespace = '', $argv = null)
767767
throw new Zend_Amf_Server_Exception('Invalid method or class; must be a classname or object');
768768
}
769769

770-
$argv = null;
770+
$args = null;
771771
if (2 < func_num_args()) {
772-
$argv = array_slice(func_get_args(), 2);
772+
$args = array_slice(func_get_args(), 2);
773773
}
774774

775775
// Use the class name as the name space by default.
@@ -780,7 +780,7 @@ public function setClass($class, $namespace = '', $argv = null)
780780

781781
$this->_classAllowed[is_object($class) ? get_class($class) : $class] = true;
782782

783-
$this->_methods[] = Zend_Server_Reflection::reflectClass($class, $argv, $namespace);
783+
$this->_methods[] = Zend_Server_Reflection::reflectClass($class, $args, $namespace);
784784
$this->_buildDispatchTable();
785785

786786
return $this;

library/Zend/XmlRpc/Server.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -278,13 +278,13 @@ public function setClass($class, $namespace = '', $argv = null)
278278
throw new Zend_XmlRpc_Server_Exception('Invalid method class', 610);
279279
}
280280

281-
$argv = null;
281+
$args = null;
282282
if (2 < func_num_args()) {
283-
$argv = func_get_args();
284-
$argv = array_slice($argv, 2);
283+
$args = func_get_args();
284+
$args = array_slice($args, 2);
285285
}
286286

287-
$dispatchable = Zend_Server_Reflection::reflectClass($class, $argv, $namespace);
287+
$dispatchable = Zend_Server_Reflection::reflectClass($class, $args, $namespace);
288288
foreach ($dispatchable->getMethods() as $reflection) {
289289
$this->_buildSignature($reflection, $class);
290290
}

0 commit comments

Comments
 (0)