function rules_token_values in Rules 6
Implementation of hook_token_values().
See also
File
- rules/
rules.module, line 1061 - Rules engine module
Code
function rules_token_values($type, $object = NULL, $options = array()) {
$values = array();
if ($type == 'string') {
$string = $object;
$values['string'] = check_plain($string);
$values['string-raw'] = $string;
}
if ($type == 'number') {
$values['number'] = (double) $object;
}
return $values;
}