public function verifyPassword(UserInterface $user, $password)
    {
        if (!$password) {
            return false;
        }

        $hashedPassword = $user->getHashedPassword();
        if (!$hashedPassword) {
            return false;
        }

        return password_verify($password, $hashedPassword);
    }
public function verifyPassword(UserInterface $user, $password)
    {
        if (!$password) {
            return false;
        }

        $hashedPassword = $user->getHashedPassword();
        if (!$hashedPassword) {
            return false;
        }

        return password_verify($password, $hashedPassword);
    }
public function verifyPassword ( UserInterface $ user , $ password ) { if ( ! $ password ) { return false ; } $ hashedPassword = $ user -> getHashedPassword ( ) ; if ( ! $ hashedPassword ) { return false ; } return password_verify ( $ password , $ hashedPassword ) ; }
Checks if a given password matches the user's password.

@param UserInterface $user
@param string        $password

@return bool
Checks if a given password matches the user s password .