function commerce_physical_customer_profile_residential in Commerce Physical Product 7
Whether or not a shipping customer profile is a residential address.
Parameters
commerce_customer_profile $profile: The customer profile whose residential status should be determined.
Return value
bool Boolean indicating whether or not the given profile has a residential address; defaults to TRUE unless otherwise determined by a custom module.
File
- ./
commerce_physical.module, line 447 - API for working with physical product types in Drupal Commerce.
Code
function commerce_physical_customer_profile_residential($profile) {
$residential = TRUE;
// Allow other modules to determine if the profile has a residential address.
drupal_alter('commerce_physical_customer_profile_residential', $residential, $profile);
return $residential;
}