Browse Source

Fix compiler warnings for unused variables

pull/2064/head
Reuben Bond 1 year ago
committed by Tarun Jain
parent
commit
631a64940e
2 changed files with 2 additions and 14 deletions
  1. +0
    -12
      src/Services/Ordering/Ordering.API/Application/Commands/CreateOrderDraftCommandHandler.cs
  2. +2
    -2
      src/Services/Webhooks/Webhooks.API/IntegrationEvents/ProductPriceChangedIntegrationEventHandler.cs

+ 0
- 12
src/Services/Ordering/Ordering.API/Application/Commands/CreateOrderDraftCommandHandler.cs View File

@ -7,17 +7,6 @@ using Microsoft.eShopOnContainers.Services.Ordering.Domain.AggregatesModel.Order
public class CreateOrderDraftCommandHandler public class CreateOrderDraftCommandHandler
: IRequestHandler<CreateOrderDraftCommand, OrderDraftDTO> : IRequestHandler<CreateOrderDraftCommand, OrderDraftDTO>
{ {
private readonly IOrderRepository _orderRepository;
private readonly IIdentityService _identityService;
private readonly IMediator _mediator;
// Using DI to inject infrastructure persistence Repositories
public CreateOrderDraftCommandHandler(IMediator mediator, IIdentityService identityService)
{
_identityService = identityService ?? throw new ArgumentNullException(nameof(identityService));
_mediator = mediator ?? throw new ArgumentNullException(nameof(mediator));
}
public Task<OrderDraftDTO> Handle(CreateOrderDraftCommand message, CancellationToken cancellationToken) public Task<OrderDraftDTO> Handle(CreateOrderDraftCommand message, CancellationToken cancellationToken)
{ {
@ -32,7 +21,6 @@ public class CreateOrderDraftCommandHandler
} }
} }
public record OrderDraftDTO public record OrderDraftDTO
{ {
public IEnumerable<OrderItemDTO> OrderItems { get; init; } public IEnumerable<OrderItemDTO> OrderItems { get; init; }


+ 2
- 2
src/Services/Webhooks/Webhooks.API/IntegrationEvents/ProductPriceChangedIntegrationEventHandler.cs View File

@ -2,8 +2,8 @@
public class ProductPriceChangedIntegrationEventHandler : IIntegrationEventHandler<ProductPriceChangedIntegrationEvent> public class ProductPriceChangedIntegrationEventHandler : IIntegrationEventHandler<ProductPriceChangedIntegrationEvent>
{ {
public async Task Handle(ProductPriceChangedIntegrationEvent @event)
public Task Handle(ProductPriceChangedIntegrationEvent @event)
{ {
int i = 0;
return Task.CompletedTask;
} }
} }

Loading…
Cancel
Save