This commit is contained in:
2021-08-27 12:24:52 +08:00
parent 0fcf75f468
commit 5f199ccb19
2 changed files with 5 additions and 22 deletions
+3 -3
View File
@@ -91,12 +91,12 @@ trait HttpParams
/**
* @return mixed
* @return string
* @throws Exception
*/
public function getRawContent(): mixed
public function getContent(): string
{
return $this->_rawContent;
return $this->_body;
}
+2 -19
View File
@@ -182,8 +182,9 @@ class Request extends HttpService implements RequestInterface
/**
* @param $value
* @return mixed
*/
public function setGrantAuthorization($value)
public function setGrantAuthorization($value): mixed
{
return $this->_grant = $value;
}
@@ -231,7 +232,6 @@ class Request extends HttpService implements RequestInterface
if (!empty($this->_platform)) {
return $this->_platform;
}
$user = $this->getAgent();
$match = preg_match('/\(.*\)?/', $user, $output);
if (!$match || count($output) < 1) {
@@ -346,23 +346,6 @@ class Request extends HttpService implements RequestInterface
return $this->isCli === TRUE;
}
/**
* @param $name
* @param $value
*
* @throws Exception
*/
public function __set($name, $value)
{
$method = 'set' . ucfirst($name);
if (method_exists($this, $method)) {
$this->$method($value);
} else {
parent::__set($name, $value); // TODO: Change the autogenerated stub
}
}
/**
* @return mixed|null
*/