You are here

public function MigratePassword::__construct in Zircon Profile 8.0

Same name and namespace in other branches
  1. 8 core/modules/user/src/MigratePassword.php \Drupal\user\MigratePassword::__construct()

Builds the replacement password service class.

Parameters

\Drupal\Core\Password\PasswordInterface $original_password: The password object.

File

core/modules/user/src/MigratePassword.php, line 37
Contains \Drupal\user\MigratePassword.

Class

MigratePassword
Replaces the original 'password' service in order to prefix the MD5 re-hashed passwords with the 'U' flag. The new salted hash is recreated on first login similarly to the D6->D7 upgrade path.

Namespace

Drupal\user

Code

public function __construct(PasswordInterface $original_password) {
  $this->originalPassword = $original_password;
}