Filter
rpress_discount_status_cleanup_count
On this page
Filters how many discounts are checked per run of the discount status cleanup.
Applied in rpress_discount_status_cleanup(), which marks discounts that reached their maximum uses or expired as inactive or expired. The value is used as posts_per_page in the discount queries. The default is 25.
Parameters#
| Parameter | Type | Description |
|---|---|---|
$value | int | Default number of discounts per query. |
Return value#
int. Number of discounts to process.
Example#
function my_discount_cleanup_count( $count ) {
return 100;
}
add_filter( 'rpress_discount_status_cleanup_count', 'my_discount_cleanup_count' );
Source#
Applied in:
includes/discount-functions.php(line 967), inrpress_discount_status_cleanup()
See also#
Was this page helpful?
