You are here

public function FloodUnblockCommands::unblockUser in Flood Unblock 8

Same name and namespace in other branches
  1. 8.2 src/Commands/FloodUnblockCommands.php \Drupal\flood_unblock\Commands\FloodUnblockCommands::unblockUser()

Clears the floods based on user.

@command flood_unblock:user @usage flood_unblock:user

Parameters

string $user: User to clear...

File

src/Commands/FloodUnblockCommands.php, line 52

Class

FloodUnblockCommands
Flood unblock. module's Drush 9 commands.

Namespace

Drupal\flood_unblock\Commands

Code

public function unblockUser($user = NULL) {
  $this->manager
    ->flood_unblock_clear_event('user.failed_login_user', $user);
  $this
    ->output()
    ->writeln('Done');
}