Automattic\WooCommerce\Admin\API\Reports\Customers

DataStore::update_registered_customer_via_last_active()public staticWC 1.0

Update the database if the "last active" meta value was changed. Function expects to be hooked into the added_user_meta updated_user_meta

Метод класса: DataStore{}

Хуков нет.

Возвращает

null. Ничего (null).

Использование

$result = DataStore::update_registered_customer_via_last_active( $meta_id, $user_id, $meta_key );
$meta_id(int) (обязательный)
ID of updated metadata entry.
$user_id(int) (обязательный)
ID of the user being updated.
$meta_key(строка) (обязательный)
Meta key being updated.

Код DataStore::update_registered_customer_via_last_active() WC 8.7.0

public static function update_registered_customer_via_last_active( $meta_id, $user_id, $meta_key ) {
	if ( 'wc_last_active' === $meta_key ) {
		self::update_registered_customer( $user_id );
	}
}