Skip to content

Commit

Permalink
Merge pull request #29 from lantongxue/patch-2
Browse files Browse the repository at this point in the history
修复Request对象getRawBody()为空的问题
  • Loading branch information
liufee committed Nov 3, 2021
2 parents 9b654a9 + dfaa655 commit 15cc6cb
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/web/Request.php
Expand Up @@ -137,7 +137,7 @@ public function getIsFlash()
public function getRawBody()
{
if ($this->_rawBody === null) {
$this->_rawBody = file_get_contents("php://input");
$this->_rawBody = $this->swooleRequest->rawContent();
return $this->_rawBody;
}

Expand Down Expand Up @@ -770,4 +770,4 @@ private function validateCsrfTokenInternal($clientSuppliedToken, $trueToken)

return $security->unmaskToken($clientSuppliedToken) === $security->unmaskToken($trueToken);
}
}
}

0 comments on commit 15cc6cb

Please sign in to comment.