改名
This commit is contained in:
@@ -66,8 +66,8 @@ abstract class BaseValidator
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @throws Exception
|
|
||||||
* @return bool
|
* @return bool
|
||||||
|
* @throws Exception
|
||||||
*/
|
*/
|
||||||
public function trigger(): bool
|
public function trigger(): bool
|
||||||
{
|
{
|
||||||
@@ -83,11 +83,14 @@ abstract class BaseValidator
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param array $data
|
* @param array|null $data
|
||||||
* @return $this
|
* @return $this
|
||||||
*/
|
*/
|
||||||
public function setParams(array $data): static
|
public function setParams(?array $data): static
|
||||||
{
|
{
|
||||||
|
if (is_null($data)) {
|
||||||
|
$data = [];
|
||||||
|
}
|
||||||
$this->params = $data;
|
$this->params = $data;
|
||||||
return $this;
|
return $this;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user