fix: Argument #2 () cannot be null
This commit is contained in:
1005
composer.lock
generated
1005
composer.lock
generated
File diff suppressed because it is too large
Load Diff
@@ -1,6 +1,7 @@
|
|||||||
<?php
|
<?php
|
||||||
namespace Bsr\Webservice;
|
namespace Bsr\Webservice;
|
||||||
|
|
||||||
|
use Bsr\Webservice\Exception\BugException;
|
||||||
use Bsr\Webservice\Exception\WebException;
|
use Bsr\Webservice\Exception\WebException;
|
||||||
use Bsr\Webservice\Formatter\Html;
|
use Bsr\Webservice\Formatter\Html;
|
||||||
|
|
||||||
@@ -16,7 +17,7 @@ class Help
|
|||||||
* @param mixed $ws
|
* @param mixed $ws
|
||||||
* @param sting $func the function to be presented
|
* @param sting $func the function to be presented
|
||||||
*/
|
*/
|
||||||
private static function func($ws, $func)
|
private static function func($ws, string $func)
|
||||||
{
|
{
|
||||||
try {
|
try {
|
||||||
$rm = new \ReflectionMethod($ws, $func);
|
$rm = new \ReflectionMethod($ws, $func);
|
||||||
|
|||||||
@@ -51,7 +51,9 @@ abstract class WebService
|
|||||||
$data["error"]["reason"] = $e->getMessage();
|
$data["error"]["reason"] = $e->getMessage();
|
||||||
$data["error"]["name"] = $e->getName();
|
$data["error"]["name"] = $e->getName();
|
||||||
|
|
||||||
|
if ($this->func !== null) {
|
||||||
$data['extra'] = Help::exception($e, $this, $this->func);
|
$data['extra'] = Help::exception($e, $this, $this->func);
|
||||||
|
}
|
||||||
|
|
||||||
$this->status = 400;
|
$this->status = 400;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user