protected function EarlyOrderProcessor::shouldRefresh in Commerce Shipping 8.2
Determines whether the order needs to be repacked and/or whether the shipping rates should be recalculated.
Parameters
\Drupal\commerce_order\Entity\OrderInterface $order: The order.
Return value
bool TRUE if it should refresh, FALSE otherwise.
2 calls to EarlyOrderProcessor::shouldRefresh()
- EarlyOrderProcessor::process in src/
EarlyOrderProcessor.php - Processes an order.
- EarlyOrderProcessor::shouldRepack in src/
EarlyOrderProcessor.php - Determines whether the given order's shipments should be repacked.
File
- src/
EarlyOrderProcessor.php, line 170
Class
- EarlyOrderProcessor
- Prepares shipments for the order refresh process.
Namespace
Drupal\commerce_shippingCode
protected function shouldRefresh(OrderInterface $order) {
return (bool) $order
->getData(ShippingOrderManagerInterface::FORCE_REFRESH, FALSE);
}