about summary refs log tree commit diff
path: root/Utilities
diff options
context:
space:
mode:
Diffstat (limited to 'Utilities')
-rw-r--r--Utilities/LibMatrix.Utilities.Bot/Services/CommandListenerHostedService.cs3
1 files changed, 1 insertions, 2 deletions
diff --git a/Utilities/LibMatrix.Utilities.Bot/Services/CommandListenerHostedService.cs b/Utilities/LibMatrix.Utilities.Bot/Services/CommandListenerHostedService.cs

index 4c6b462..d0a93a4 100644 --- a/Utilities/LibMatrix.Utilities.Bot/Services/CommandListenerHostedService.cs +++ b/Utilities/LibMatrix.Utilities.Bot/Services/CommandListenerHostedService.cs
@@ -25,7 +25,7 @@ public class CommandListenerHostedService( private FrozenSet<ICommand> _commands = null!; private Task? _listenerTask; - private CancellationTokenSource _cts = new(); + private readonly CancellationTokenSource _cts = new(); private long _startupTime = DateTimeOffset.UtcNow.ToUnixTimeMilliseconds(); /// <summary>Triggered when the application host is ready to start the service.</summary> @@ -61,7 +61,6 @@ public class CommandListenerHostedService( Timeout = config.SyncConfiguration.Timeout ?? 30_000, MinimumDelay = config.SyncConfiguration.MinimumSyncTime ?? TimeSpan.Zero, SetPresence = config.SyncConfiguration.Presence ?? botConfig.Presence, - }; syncHelper.SyncReceivedHandlers.Add(async sync => {