Skip to content

Commit 890e909

Browse files
Merge branch '5.3' into 5.4
* 5.3: Backport type fixes fix annot Backport type fixes Fix CS Avoid triggering the autoloader in Deprecation::isLegacy() fix markdown markup Backport type fixes uzb translation [DependencyInjection] Fix doc blocks [DependencyInjection] Turn $defaultDeprecationTemplate into a constant [GHA] restore phpunit-bridge job rethrow caught exception [Form] better form doc types to support static analysis
2 parents 4dc7135 + 9b4992c commit 890e909

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

Validator/Constraints/UserPasswordValidator.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,10 @@ public function validate($password, Constraint $constraint)
5656
return;
5757
}
5858

59+
if (!\is_string($password)) {
60+
throw new UnexpectedTypeException($password, 'string');
61+
}
62+
5963
$user = $this->tokenStorage->getToken()->getUser();
6064

6165
if (!$user instanceof UserInterface) {

0 commit comments

Comments
 (0)