autoship_lock_duration_restriction_days

(src > schedule-orders.php) Can be used to modify the lock duration on a Site, Autoship Order, or even Customer basis. The filter takes the current QPilot Lock Duration days, the current Autoship Order, and the current Customer ID as parameters. This filter for example would allow Merchants to enforce longer Lock Durations for orders that contain specific products.

Example

// enforce a custom lock duration without enabling lock duration through QPilot enforce a stricter lock on 
// specific customer
function xx_custom_lock_duration($lock_days, $order_id, $customer_id){
    $customer_id == 231 ? 5 : 3;
}
  add_filter('autoship_lock_duration_restriction_days', 'xx_custom_lock_duration', 10, 3 );