fc_pro_address_book_entry_compare_field_keys_skip_list

Back to list of all filter and action hooks for Address Book for WooCommerce.

Description #

Define fields to skip when comparing whether two address book entries should be considered the equal.

This filter is applied during address comparison operations, including:

  • Checking for duplicate addresses before saving new entries.
  • Determining if shipping and billing addresses are the same.
  • Preventing unnecessary address saves when addresses haven’t changed.
  • Setting default address flags when addresses match.

Parameters #

  • $skip_field_keys (array) Array of field keys to skip during comparison.

Examples #

/**
 * Skip company and phone fields when checking if address entries are the same.
 * This changes the default behavior: ignores company and phone number fields
 * when comparing address book entries.
 */
function skip_company_phone_in_comparison_check( $skip_field_keys ) {
    // Add company and phone to skip list
    $skip_field_keys[] = 'company';
    $skip_field_keys[] = 'phone';
    
    return $skip_field_keys;
}
add_filter( 'fc_pro_address_book_entry_compare_field_keys_skip_list', 'skip_company_phone_in_comparison_check', 10 );

What are your feelings

Updated on December 15, 2025