| Conditions | 2 |
| Paths | 2 |
| Total Lines | 10 |
| Code Lines | 5 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 39 | public function getProductBundleForProduct(ProductInterface $product): ProductBundleInterface |
||
| 40 | { |
||
| 41 | /** @var ProductBundleInterface $productBundle */ |
||
| 42 | $productBundle = $this->productBundleRepository->findOneBy(['product' => $product]); |
||
| 43 | if ($productBundle instanceof ProductBundleInterface === false) { |
||
| 44 | throw new ProductIsNotAProductBundleException($product); |
||
| 45 | } |
||
| 46 | |||
| 47 | return $productBundle; |
||
| 48 | } |
||
| 49 | } |
||
| 50 |