Filter
rpress_decrease_store_earnings_on_pending
On this page
Filters whether moving a payment back to pending reduces store earnings.
Applied in RPRESS_Payment::process_pending and passed to maybe_alter_stats. Return false to leave store earnings unchanged when a completed payment goes back to a pending or processing status.
Parameters#
| Parameter | Type | Description |
|---|---|---|
$decrease | bool | True to reduce the value. The default is true. |
$payment | RPRESS_Payment | The payment object. |
Return value#
bool. Whether to reduce the value.
Example#
function my__decrease_store_earnings_on_pending( $decrease, $payment ) {
return false;
}
add_filter( 'rpress_decrease_store_earnings_on_pending', 'my__decrease_store_earnings_on_pending', 10, 2 );
Source#
Applied in:
includes/payments/class-rpress-payment.php(line 1699), inRPRESS_Payment::process_pending()
See also#
Was this page helpful?
