| Total Complexity | 3 |
| Total Lines | 23 |
| Duplicated Lines | 0 % |
| Coverage | 0% |
| Changes | 0 | ||
| 1 | <?php |
||
| 9 | class PasswordLengthValidator implements Validator |
||
| 10 | { |
||
| 11 | /** @var int $length */ |
||
| 12 | private $length; |
||
| 13 | |||
| 14 | /** |
||
| 15 | * PasswordLengthValidator constructor. |
||
| 16 | * |
||
| 17 | * @param int $length The minimum length the password must be |
||
| 18 | */ |
||
| 19 | public function __construct(int $length = 8) |
||
| 20 | { |
||
| 21 | $this->length = $length; |
||
| 22 | } |
||
| 23 | |||
| 24 | /** {@inheritdoc} */ |
||
| 25 | public function validate(string $password): bool |
||
| 32 | } |
||
| 33 | } |
||
| 34 |