// product data was never detected and the product is not inside the data collection
if ($product !== null ||
$item->
getDataTimestamp() !== null
) { return;
} if ($behavior->
hasPermission(self::KEEP_INACTIVE_PRODUCT
)) { return;
} $cart->
addErrors(new ProductNotFoundError($item->
getLabel() ?:
$item->
getId()));
$items->
remove($item->
getId());
} private function validateParents(LineItem
$item, CartDataCollection
$data, LineItemCollection
$items): void
{ $product =
$data->
get( $this->
getDataKey((string) $item->
getReferencedId()) );
// no data for enrich exists