woocommerce_logger_days_to_retain_logs хук-фильтрWC 3.4.0

Clear all logs older than a defined number of days. Defaults to 30 days.

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

add_filter( 'woocommerce_logger_days_to_retain_logs', 'wp_kama_woocommerce_logger_days_to_retain_logs_filter' );

/**
 * Function for `woocommerce_logger_days_to_retain_logs` filter-hook.
 * 
 * @param  $30 
 *
 * @return 
 */
function wp_kama_woocommerce_logger_days_to_retain_logs_filter( $30 ){

	// filter...
	return $30;
}
$30
-

Список изменений

С версии 3.4.0 Введена.

Где вызывается хук

WC_Logger::clear_expired_logs()
woocommerce_logger_days_to_retain_logs
woocommerce/includes/class-wc-logger.php 306
$days      = absint( apply_filters( 'woocommerce_logger_days_to_retain_logs', 30 ) );

Где используется хук в WooCommerce

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