You are here

function role_watchdog_user in Role Watchdog 5

Same name and namespace in other branches
  1. 6.2 role_watchdog.module \role_watchdog_user()
  2. 6 role_watchdog.module \role_watchdog_user()

Implementation of hook_user().

Adds submit hook to monitor role changes.

File

./role_watchdog.module, line 82
Logs changes to user roles.

Code

function role_watchdog_user($type, &$edit, &$account, $category = NULL) {
  if ($type == 'submit' && $category == 'account') {
    if (user_access('administer access control')) {
      return role_watchdog_user_edit_submit(arg(1), $edit, $account);
    }
  }
}