WordPress at Your Fingertips
function is not described

WC_Auth::maybe_delete_key() private WC 2.4.0

Maybe delete key.

{} It's a method of the class: WC_Auth{}

No Hooks.

Return

null. Nothing.

Usage

// private - for code of main (parent) class only
$result = $this->maybe_delete_key( $key );
$key(array) (required)
Key.

Changelog

Since 2.4.0 Introduced.

Code of WC_Auth::maybe_delete_key() WC 5.8.0

private function maybe_delete_key( $key ) {
	global $wpdb;

	if ( isset( $key['key_id'] ) ) {
		$wpdb->delete( $wpdb->prefix . 'woocommerce_api_keys', array( 'key_id' => $key['key_id'] ), array( '%d' ) );
	}
}