Skip to content

Commit

Permalink
[PasswordHasher] Remove PasswordHasherAwareInterface from UserPasswor…
Browse files Browse the repository at this point in the history
…dHasherInterface API
  • Loading branch information
chalasr committed Jun 11, 2021
1 parent 517555f commit 02320f9
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions Hasher/UserPasswordHasher.php
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ public function __construct(PasswordHasherFactoryInterface $hasherFactory)
}

/**
* @param PasswordAuthenticatedUserInterface|PasswordHasherAwareInterface $user
* @param PasswordAuthenticatedUserInterface $user
*/
public function hashPassword($user, string $plainPassword): string
{
Expand All @@ -54,7 +54,7 @@ public function hashPassword($user, string $plainPassword): string
}

/**
* @param PasswordAuthenticatedUserInterface|PasswordHasherAwareInterface $user
* @param PasswordAuthenticatedUserInterface $user
*/
public function isPasswordValid($user, string $plainPassword): bool
{
Expand All @@ -80,7 +80,7 @@ public function isPasswordValid($user, string $plainPassword): bool
}

/**
* @param PasswordAuthenticatedUserInterface|PasswordHasherAwareInterface $user
* @param PasswordAuthenticatedUserInterface $user
*/
public function needsRehash($user): bool
{
Expand Down
6 changes: 3 additions & 3 deletions Hasher/UserPasswordHasherInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@
*
* @author Ariel Ferrandini <[email protected]>
*
* @method string hashPassword(PasswordAuthenticatedUserInterface|PasswordHasherAwareInterface $user, string $plainPassword) Hashes the plain password for the given user.
* @method bool isPasswordValid(PasswordAuthenticatedUserInterface|PasswordHasherAwareInterface $user, string $plainPassword) Checks if the plaintext password matches the user's password.
* @method bool needsRehash(PasswordAuthenticatedUserInterface|PasswordHasherAwareInterface $user) Checks if an encoded password would benefit from rehashing.
* @method string hashPassword(PasswordAuthenticatedUserInterface $user, string $plainPassword) Hashes the plain password for the given user.
* @method bool isPasswordValid(PasswordAuthenticatedUserInterface $user, string $plainPassword) Checks if the plaintext password matches the user's password.
* @method bool needsRehash(PasswordAuthenticatedUserInterface $user) Checks if an encoded password would benefit from rehashing.
*/
interface UserPasswordHasherInterface
{
Expand Down

0 comments on commit 02320f9

Please sign in to comment.