Skip to content

Commit

Permalink
fix: swoft-cloud/swoft/issues/1286 collect params error
Browse files Browse the repository at this point in the history
  • Loading branch information
inhere committed May 15, 2020
1 parent 786f812 commit f279153
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/rpc-server/src/Request.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
use Swoft\Rpc\Packet;
use Swoft\Rpc\Server\Contract\RequestInterface;
use Swoole\Server;
use function microtime;

/**
* Class Request
Expand Down Expand Up @@ -134,9 +135,8 @@ public function getParamsMap(): array
$rc = BeanFactory::getReflection($this->interface);
$rxParams = $rc['methods'][$this->method]['params'];

$index = 0;
$paramsMap = [];
foreach ($rxParams as $methodParams) {
foreach ($rxParams as $index => $methodParams) {
if (!isset($this->params[$index])) {
break;
}
Expand Down

0 comments on commit f279153

Please sign in to comment.