You are here

function masquerade_user_operations_masquerade in Masquerade 7

Callback for user operation.

1 string reference to 'masquerade_user_operations_masquerade'
masquerade_user_operations in ./masquerade.module
Implements hook_user_operations().

File

./masquerade.module, line 207
The masquerade module allows administrators to masquerade as other user.

Code

function masquerade_user_operations_masquerade(array $accounts) {

  // Only process the first account since switching to multiple makes no sense.
  if (($uid = current($accounts)) && masquerade_menu_access('switch', $uid)) {
    masquerade_switch_user($uid);
  }
}