function commerce_addressbook_rules_profile_is_default in Commerce Addressbook 7.2
Same name and namespace in other branches
- 7.3 commerce_addressbook.rules.inc \commerce_addressbook_rules_profile_is_default()
Rules condition: checks if profile is user's default customer profile.
Parameters
$customer_profile: The customer profile to check.
Return value
bool TRUE or FALSE if profile IDs match.
1 string reference to 'commerce_addressbook_rules_profile_is_default'
File
- ./
commerce_addressbook.rules.inc, line 61 - Rules integration for Commerce Addressbook.
Code
function commerce_addressbook_rules_profile_is_default($customer_profile) {
return commerce_addressbook_get_default_profile_id($customer_profile->uid, $customer_profile->type) == $customer_profile->profile_id;
}