You are here

function tfa_basic_setup_access in TFA Basic plugins 7

Access control.

Parameters

object $account:

string $permission:

Return value

bool

1 string reference to 'tfa_basic_setup_access'
tfa_basic_menu in ./tfa_basic.module
Implements hook_menu().

File

./tfa_basic.module, line 130

Code

function tfa_basic_setup_access($account, $permission = '') {
  $administer_users = user_access('administer users') && $account->uid > 0;
  $is_account = $GLOBALS['user']->uid == $account->uid;
  return $is_account && user_access($permission, $account) || $administer_users;
}