<?php
if (!defined('ABSPATH')) exit;

add_action('stakmv_auction_recovery_cron', function () {
    // phpcs:disable WordPress.DB.SlowDBQuery.slow_db_query_meta_key -- Recovery cron intentionally targets auction-tagged pending orders.
    $orders = wc_get_orders([
        'status' => 'pending',
        'meta_key' => '_stakmv_auction_id',
        'limit' => -1,
    ]);
    // phpcs:enable WordPress.DB.SlowDBQuery.slow_db_query_meta_key

    foreach ($orders as $order) {
        // recovery logic later
    }
});
