You are here

function userpoints_rules_userpoints in User Points 6

Same name and namespace in other branches
  1. 7 userpoints_rules.module \userpoints_rules_userpoints()

Rules events -Trigger event when user points awarded.

File

./userpoints_rules.module, line 11
Rules integration for the user points module.

Code

function userpoints_rules_userpoints($op, $params = '') {
  switch ($op) {
    case 'points after':
      $account = user_load($params['uid']);
      rules_invoke_event('userpoints_event_points_awarded', $account, $params);
      break;
  }
}