microsoft/teams.net

Public

mirrored from https://github.com/microsoft/teams.netAvailable

CodeCommitsIssuesPull requestsActionsInsightsSecurity
v2.0.0-preview.6

Branches

Tags

  • No tags available.
0Branches0Tags
Go to file
Add file
Code

Clone

HTTPS

Download ZIP

Libraries/Microsoft.Teams.Extensions/Microsoft.Teams.Extensions.Logging/LogLevelExtensions.cs

17lines · modecode

1using Microsoft.Extensions.Logging;
2
3namespace Microsoft.Teams.Extensions.Logging;
4
5public static class LogLevelExtensions
6{
7 public static Common.Logging.LogLevel ToTeams(this LogLevel level)
8 {
9 return level switch
10 {
11 LogLevel.Information => Common.Logging.LogLevel.Info,
12 LogLevel.Warning => Common.Logging.LogLevel.Warn,
13 LogLevel.Error or LogLevel.Critical => Common.Logging.LogLevel.Error,
14 _ => Common.Logging.LogLevel.Debug
15 };
16 }
17}