Skip to content

Commit 314bb57

Browse files
committed
Replace loglevel with loggerfactory in config
1 parent 78f0fe4 commit 314bb57

File tree

2 files changed

+5
-12
lines changed

2 files changed

+5
-12
lines changed

src/Discord.Net.Commands/CommandServiceConfig.cs

+2-4
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
using Microsoft.Extensions.Logging;
12
using System.Collections.Generic;
23

34
namespace Discord.Commands
@@ -23,10 +24,7 @@ public class CommandServiceConfig
2324
/// </summary>
2425
public bool CaseSensitiveCommands { get; set; } = false;
2526

26-
/// <summary>
27-
/// Gets or sets the minimum log level severity that will be sent to the <see cref="CommandService.Log"/> event.
28-
/// </summary>
29-
public LogSeverity LogLevel { get; set; } = LogSeverity.Info;
27+
public ILoggerFactory LoggerFactory { get; set; }
3028

3129
/// <summary>
3230
/// Gets or sets whether <see cref="RunMode.Sync"/> commands should push exceptions up to the caller.

src/Discord.Net.Core/DiscordConfig.cs

+3-8
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
using Microsoft.Extensions.Logging;
12
using System.Reflection;
23

34
namespace Discord
@@ -123,14 +124,8 @@ public class DiscordConfig
123124
/// The currently set <see cref="RetryMode"/>.
124125
/// </returns>
125126
public RetryMode DefaultRetryMode { get; set; } = RetryMode.AlwaysRetry;
126-
127-
/// <summary>
128-
/// Gets or sets the minimum log level severity that will be sent to the Log event.
129-
/// </summary>
130-
/// <returns>
131-
/// The currently set <see cref="LogSeverity"/> for logging level.
132-
/// </returns>
133-
public LogSeverity LogLevel { get; set; } = LogSeverity.Info;
127+
128+
public ILoggerFactory LoggerFactory { get; set; }
134129

135130
/// <summary>
136131
/// Gets or sets whether the initial log entry should be printed.

0 commit comments

Comments
 (0)