about summary refs log tree commit diff
path: root/Utilities/LibMatrix.DebugDataValidationApi/Controllers
diff options
context:
space:
mode:
authorEmma [it/its]@Rory& <root@rory.gay>2023-12-14 07:20:46 +0100
committerEmma [it/its]@Rory& <root@rory.gay>2023-12-14 07:20:46 +0100
commit5affd9f061e75f6575a2fe6715f9e8757cfe87e8 (patch)
tree13ea35ce981094a960746777a16dff8815c45e55 /Utilities/LibMatrix.DebugDataValidationApi/Controllers
parentTemp state (diff)
downloadLibMatrix-5affd9f061e75f6575a2fe6715f9e8757cfe87e8.tar.xz
Cleanup
Diffstat (limited to 'Utilities/LibMatrix.DebugDataValidationApi/Controllers')
-rw-r--r--Utilities/LibMatrix.DebugDataValidationApi/Controllers/ValidationController.cs5
1 files changed, 2 insertions, 3 deletions
diff --git a/Utilities/LibMatrix.DebugDataValidationApi/Controllers/ValidationController.cs b/Utilities/LibMatrix.DebugDataValidationApi/Controllers/ValidationController.cs
index 81753d1..1b93614 100644
--- a/Utilities/LibMatrix.DebugDataValidationApi/Controllers/ValidationController.cs
+++ b/Utilities/LibMatrix.DebugDataValidationApi/Controllers/ValidationController.cs
@@ -7,16 +7,15 @@ namespace LibMatrix.DebugDataValidationApi.Controllers;
 [ApiController]
 [Route("/")]
 public class ValidationController(ILogger<ValidationController> logger) : ControllerBase {
-    private readonly ILogger<ValidationController> _logger = logger;
 
     [HttpPost("/validate/{type}")]
     public Task<bool> Get([FromRoute] string type, [FromBody] JsonElement content) {
         var t = Type.GetType(type);
         if (t is null) {
-            Console.WriteLine($"Type `{type}` does not exist!");
+            logger.LogWarning($"Type `{type}` does not exist!");
             throw new ArgumentException($"Unknown type {type}!");
         }
-        Console.WriteLine($"Validating {type}...");
+        logger.LogInformation($"Validating {type}...");
         return Task.FromResult(content.FindExtraJsonElementFields(t, "$"));
     }
 }