public function encodePassword($raw, $salt)
if ($this->isPasswordTooLong($raw)) {
throw new BadCredentialsException('Invalid password.');
$options = array('cost' => $this->cost);
@trigger_error('Passing a $salt to '.__METHOD__.'() is deprecated since Symfony 2.8 and will be ignored in 3.0.', E_USER_DEPRECATED);
$options['salt'] = $salt;
return password_hash($raw, PASSWORD_BCRYPT, $options);