Action
rpress_account_hub_address_deleted
On this page
Fires after a customer address is deleted in the account hub.
Runs at the end of rpress_account_hub_delete_address(), after the address is removed and, if it was the default, another address has been made the default or the default meta cleared.
Parameters#
| Parameter | Type | Description |
|---|---|---|
$user_id | int | User ID. |
$index | int | Index of the deleted address. |
Example#
add_action( 'rpress_account_hub_address_deleted', 'my_address_deleted', 10, 2 );
function my_address_deleted( $user_id, $index ) {
delete_user_meta( $user_id, '_my_address_extra_' . $index );
}
Source#
Fired from:
includes/features/account-hub/addresses.php(line 288), inrpress_account_hub_delete_address()
See also#
Was this page helpful?
