diff --git a/backend/core/src/Core.Application/Queries/CustomerQueries/GetCustomerQuery.cs b/backend/core/src/Core.Application/Queries/CustomerQueries/GetCustomerQuery.cs index d65e8f42..7b42bdb2 100644 --- a/backend/core/src/Core.Application/Queries/CustomerQueries/GetCustomerQuery.cs +++ b/backend/core/src/Core.Application/Queries/CustomerQueries/GetCustomerQuery.cs @@ -2,9 +2,7 @@ // under the Apache License, Version 2.0. See the NOTICE file at the root // of this distribution or at http://www.apache.org/licenses/LICENSE-2.0 -using Core.Domain; using Core.Domain.Entities.CustomerAggregate; -using Core.Domain.Exceptions; using Core.Domain.Repositories; using MediatR; @@ -33,11 +31,6 @@ public async Task Handle(GetCustomerQuery request, CancellationToken c { var customer = await _customerRepository.GetAsync(request.CustomerCode); - if (customer.Status != CustomerStatus.ACTIVE.ToString() && customer.Status != CustomerStatus.UNDERREVIEW.ToString()) - { - throw new CustomErrorsException(ApplicationErrorCode.InvalidStatusError.ToString(), request.CustomerCode, "Customer status with this reference is not valid"); - } - return customer; } }