You are here

function userpoints_action_grant_points in User Points 5.3

Same name and namespace in other branches
  1. 6 userpoints_rules.rules.inc \userpoints_action_grant_points()
  2. 7.2 userpoints_rules/userpoints_rules.rules.inc \userpoints_action_grant_points()
  3. 7 userpoints_rules.rules.inc \userpoints_action_grant_points()

Implementation of a workflow-ng action: grant points to a user

File

./userpoints_workflow_ng.module, line 42
Some workflow-ng integration for the user points module

Code

function userpoints_action_grant_points($user, $settings, &$arguments, &$log) {
  extract(workflow_ng_token_replace_all(array(
    'number',
  ), $settings, $arguments, $log));
  userpoints_userpointsapi(array(
    'uid' => $user->uid,
    'points' => $number,
  ));
}