WC_Customer::delete_and_reassign( int $reassign = null )
Delete a customer and reassign posts.
Description Description
.
Parameters Parameters
- $reassign
-
(Optional) Reassign posts and links to new User ID.
Default value: null
Return Return
(bool)
Source Source
File: includes/class-wc-customer.php
public function delete_and_reassign( $reassign = null ) {
if ( $this->data_store ) {
$this->data_store->delete(
$this,
array(
'force_delete' => true,
'reassign' => $reassign,
)
);
$this->set_id( 0 );
return true;
}
return false;
}
Changelog Changelog
| Version | Description |
|---|---|
| 3.0.0 | Introduced. |