| Conditions | 1 |
| Paths | 1 |
| Total Lines | 9 |
| Code Lines | 4 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 37 | public function getOneByToken(string $orderToken): CartSummaryView |
||
| 38 | { |
||
| 39 | /** @var OrderInterface $cart */ |
||
| 40 | $cart = $this->cartRepository->findOneBy(['tokenValue' => $orderToken]); |
||
| 41 | |||
| 42 | Assert::notNull($cart, 'Cart with given id does not exists'); |
||
| 43 | |||
| 44 | return $this->cartViewFactory->create($cart, $cart->getLocaleCode()); |
||
| 45 | } |
||
| 46 | } |
||
| 47 |