function party_user_rules_get_party in Party 7
Implement the get a party from a user rule.
Parameters
stdClass $account: A user object.
array $settings: The rules config settings.
Return value
array An array with the following key-value pairs:
- party: The party object for the given user.
1 string reference to 'party_user_rules_get_party'
- party_user_rules_action_info in modules/
party_user/ party_user.rules.inc - Implements hook_rules_action_info()
File
- modules/
party_user/ party_user.rules.inc, line 47 - Rules integration for party user.
Code
function party_user_rules_get_party($account = NULL, $settings = array()) {
if (!$account) {
global $user;
$account = $user;
}
return array(
'party' => party_user_get_party($account),
);
}