diff --git a/Src/Dlhis.Middle/Controllers/GainfosController.cs b/Src/Dlhis.Middle/Controllers/GainfosController.cs index dc60ef38..5be9a57a 100644 --- a/Src/Dlhis.Middle/Controllers/GainfosController.cs +++ b/Src/Dlhis.Middle/Controllers/GainfosController.cs @@ -13,11 +13,13 @@ public class GainfosController : ControllerBase { private readonly IHttpClientFactory _httpClientFactory; private readonly IConfiguration _configuration; + private readonly ILogger _logger; - public GainfosController(IHttpClientFactory httpClientFactory, IConfiguration configuration) + public GainfosController(IHttpClientFactory httpClientFactory, IConfiguration configuration, ILogger logger) { _httpClientFactory = httpClientFactory; _configuration = configuration; + _logger = logger; } /// @@ -33,6 +35,8 @@ public class GainfosController : ControllerBase var hostName = _configuration.GetSection("HostName").Value; var httpClient = _httpClientFactory.CreateClient(); + _logger.LogInformation("token:{token}", token); + try { var faceBytes = await httpClient.GetByteArrayAsync($"https://{hostName}/api/basic/gainfos/face?token={token}");