public OrdersController( IOrderService orderService, ICompleteOrderService completeOrderService) { this.orderService = orderService ?? throw new ArgumentNullException(nameof(orderService)); if (completeOrderService is null) { throw new ArgumentNullException(nameof(completeOrderService)); } updateOrderStatusActionFactory.Add(OrderStatus.Complete, completeOrderService.CompleteAsync); }
public CheckoutController(IGatewayAuthenticationService gatewayAuthenticationService, IGatewayCheckoutService gatewayChekoutService, ICompleteOrderService completeOrderService) { _gatewayAuthenticationService = gatewayAuthenticationService; _gatewayChekoutService = gatewayChekoutService; _completeOrderService = completeOrderService; }