public getById ( |
||
$id | ||
return |
public function getById(OrderId $id) : Order
{
$order = $this->entityManager->getRepository(Order::class)->findOneBy(['id.id' => $id]);
if (is_null($order)) {
throw new OrderNotFoundException();
}
return $order;
}