You are here

public function ForcePasswordChangeMapper::updateExpiryForRole in Force Password Change 8

Same name and namespace in other branches
  1. 2.0.x src/Mapper/ForcePasswordChangeMapper.php \Drupal\force_password_change\Mapper\ForcePasswordChangeMapper::updateExpiryForRole()

*

Overrides ForcePasswordChangeMapperInterface::updateExpiryForRole

File

src/Mapper/ForcePasswordChangeMapper.php, line 104

Class

ForcePasswordChangeMapper

Namespace

Drupal\force_password_change\Mapper

Code

public function updateExpiryForRole($rid, $time_period, $weight) {
  $this->connection
    ->update('force_password_change_expiry')
    ->fields([
    'expiry' => $time_period,
    'weight' => $weight,
  ])
    ->condition('rid', $rid)
    ->execute();
}