From 207e41c25122ab872beaeb4b68d713554d34275e Mon Sep 17 00:00:00 2001 From: Shantanu Date: Mon, 1 Jul 2024 12:24:49 +1000 Subject: [PATCH] minor refactoring. moved locationn of MyHttpClient class. --- AspNetCore.ApiGateway/Application/ApiGatewayOptions.cs | 10 ---------- AspNetCore.ApiGateway/Application/HttpService.cs | 10 ++++++++++ 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/AspNetCore.ApiGateway/Application/ApiGatewayOptions.cs b/AspNetCore.ApiGateway/Application/ApiGatewayOptions.cs index 080bd19..2f7012b 100644 --- a/AspNetCore.ApiGateway/Application/ApiGatewayOptions.cs +++ b/AspNetCore.ApiGateway/Application/ApiGatewayOptions.cs @@ -10,14 +10,4 @@ public class ApiGatewayOptions public Action DefaultHttpClientConfigure { get; set; } public Func DefaultMyHttpClient { get; set; } } - - public class MyHttpClient: IHttpService - { - public HttpClient Client { get; private set; } - - public MyHttpClient(HttpClientHandler clientHandler) - { - Client = new HttpClient(clientHandler); - } - } } diff --git a/AspNetCore.ApiGateway/Application/HttpService.cs b/AspNetCore.ApiGateway/Application/HttpService.cs index 74f0aaa..895287d 100644 --- a/AspNetCore.ApiGateway/Application/HttpService.cs +++ b/AspNetCore.ApiGateway/Application/HttpService.cs @@ -16,4 +16,14 @@ public HttpService(HttpClient client) public HttpClient Client { get; } } + + public class MyHttpClient : IHttpService + { + public HttpClient Client { get; private set; } + + public MyHttpClient(HttpClientHandler clientHandler) + { + Client = new HttpClient(clientHandler); + } + } }