order = new OrderObject($orderId); $this->step = new StepObject(self::STEP_REFERENCE, $completeDate); } /** * @return bool */ public function validator(): bool { if(!ShippingArrangement::where('order_id', $this->order->getOrderId())->exists()) { return false; } return true; } /** * @return JsonResponse * @throws InternalServerErrorException */ public function execute(): JsonResponse { return $this->handler($this->order, $this->step); } }