From c0c65c2bb8153520fc25c7520bb7e3b17195e0e9 Mon Sep 17 00:00:00 2001 From: atef Date: Mon, 3 Jul 2023 14:21:18 +0200 Subject: [PATCH] Add Log Error and log Warning --- csharp/App/SaliMax/src/Logger.cs | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/csharp/App/SaliMax/src/Logger.cs b/csharp/App/SaliMax/src/Logger.cs index f89ecb653..666cad058 100644 --- a/csharp/App/SaliMax/src/Logger.cs +++ b/csharp/App/SaliMax/src/Logger.cs @@ -24,4 +24,16 @@ public static class Logger _logger.LogDebug(t.ToString()); // TODO: check warning return t; } + + public static T LogError(this T t) where T : notnull + { + _logger.LogError(t.ToString()); // TODO: check warning + return t; + } + + public static T LogWarning(this T t) where T : notnull + { + _logger.LogWarning(t.ToString()); // TODO: check warning + return t; + } } \ No newline at end of file