You are here

function referral_userpoints_referral in User Referral 6

Implementation of hook_referral

File

referral_userpoints/referral_userpoints.module, line 11

Code

function referral_userpoints_referral($new_uid, $referring_uid) {
  userpoints_userpointsapi(array(
    'points' => variable_get(REFERRAL_USERPOINTS, 0),
    'uid' => $referring_uid,
    'operation' => 'referral',
    'entity_id' => $referring_uid,
    'entity_type' => 'user',
    'reference' => 'referral',
    'tid' => variable_get(REFERRAL_USERPOINTS_TID, 0),
    'moderate' => variable_get(REFERRAL_USERPOINTS_MODERATION, 0),
  ));
}