You are here

function user_flood_test_user_flood_control in Drupal 7

Implements hook_user_flood_control().

File

modules/user/tests/user_flood_test.module, line 11
Dummy module implementing hook_user_flood_control.

Code

function user_flood_test_user_flood_control($ip, $username = FALSE) {
  if (!empty($username)) {
    watchdog('user_flood_test', 'hook_user_flood_control was passed username %username and IP %ip.', array(
      '%username' => $username,
      '%ip' => $ip,
    ));
  }
  else {
    watchdog('user_flood_test', 'hook_user_flood_control was passed IP %ip.', array(
      '%ip' => $ip,
    ));
  }
}