You are here

function rules_condition_user_referred in User Referral 7

Rules condition callback

1 string reference to 'rules_condition_user_referred'
referral_rules_condition_info in ./referral.rules.inc
Implements hook_rules_condition_info().

File

./referral.rules.inc, line 176
Rules integration

Code

function rules_condition_user_referred($user) {
  $result = db_query_range('SELECT referral_uid FROM {referral} WHERE uid = :uid', 0, 1, array(
    'uid' => $user->uid,
  ))
    ->fetchField();
  return $result;
}