Skip to content
Docs
Get RestroPress

Filter

rpress_order_alerts_escalation_batch

Updated
On this page

Filters how many orders the escalation query fetches per page.

Runs in RPRESS_Order_Alerts::run_escalation_check() while the WP_Query arguments are built, and becomes posts_per_page. The check pages through results up to ten times, so this controls page size rather than a hard cap. The default is 50. The value is cast to an integer.

Parameters#

ParameterTypeDescription
$valueintOrders per query page.

Return value#

int. Posts per page.

Example#

function my_escalation_batch( $batch ) {
	return 25;
}
add_filter( 'rpress_order_alerts_escalation_batch', 'my_escalation_batch' );

Notes#

rpress_order_alerts_escalation_query_args runs afterwards and can override posts_per_page again.

Source#

Applied in:

  • includes/features/order-alerts/loader.php (line 524), in RPRESS_Order_Alerts::run_escalation_check()

See also#

Was this page helpful?