-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #46 from SandroMiguel/feat/improve-errors-phpdoc
feat(src/validator.php): improve phpdoc
- Loading branch information
Showing
1 changed file
with
4 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,8 +6,7 @@ | |
* @package Verum-PHP | ||
* @license MIT https://github.com/SandroMiguel/verum-php/blob/master/LICENSE | ||
* @author Sandro Miguel Marques <[email protected]> | ||
* @link https://github.com/SandroMiguel/verum-php | ||
* @version 4.2.2 (2024-03-21) | ||
* @version 4.2.3 (2024-10-21) | ||
*/ | ||
|
||
declare(strict_types=1); | ||
|
@@ -82,7 +81,7 @@ final class Validator | |
* ... | ||
* ] | ||
* | ||
* @var array<mixed> Errors list | ||
* @var array<string,array<string,mixed>> Errors list | ||
*/ | ||
private $errors = []; | ||
|
||
|
@@ -320,10 +319,7 @@ public function getFieldRules(): array | |
/** | ||
* Errors messages. | ||
* | ||
* @return array<mixed> Returns the error messages. | ||
* | ||
* @version 1.0.0 (30/04/2020) | ||
* @since Verum 1.0.0 | ||
* @return array<string,array<string,mixed>> Returns the error messages. | ||
*/ | ||
public function getErrors(): array | ||
{ | ||
|
@@ -449,7 +445,7 @@ private function getMultiNameFieldValues(string $fieldName): array | |
[$baseFieldName] = \explode('.', $fieldName); | ||
$fieldValues = \array_filter( | ||
$this->fieldValues, | ||
static fn ($key) => \strpos($key, $baseFieldName) === 0, | ||
static fn($key) => \strpos($key, $baseFieldName) === 0, | ||
\ARRAY_FILTER_USE_KEY | ||
); | ||
|
||
|