broadcast bypass toggle gone
This commit is contained in:
@@ -403,7 +403,7 @@ public class BroadcastService : IHostedService, IMediatorSubscriber
|
||||
|
||||
|
||||
|
||||
public async void ToggleBroadcast(bool bypassCooldown = false)
|
||||
public async void ToggleBroadcast()
|
||||
{
|
||||
|
||||
if (!IsLightFinderAvailable)
|
||||
@@ -419,7 +419,7 @@ public class BroadcastService : IHostedService, IMediatorSubscriber
|
||||
await RequireConnectionAsync(nameof(ToggleBroadcast), async () =>
|
||||
{
|
||||
var cooldown = RemainingCooldown;
|
||||
if (!bypassCooldown && !_config.Current.BroadcastEnabled && cooldown is { } cd && cd > TimeSpan.Zero)
|
||||
if (!_config.Current.BroadcastEnabled && cooldown is { } cd && cd > TimeSpan.Zero)
|
||||
{
|
||||
_logger.LogWarning("Cooldown active. Must wait {Remaining}s before re-enabling.", cd.TotalSeconds);
|
||||
_mediator.Publish(new NotificationMessage(
|
||||
@@ -556,7 +556,7 @@ public class BroadcastService : IHostedService, IMediatorSubscriber
|
||||
OnClick = (n) =>
|
||||
{
|
||||
_logger.LogInformation("Re-enabling broadcast from notification");
|
||||
ToggleBroadcast(bypassCooldown: true);
|
||||
ToggleBroadcast();
|
||||
n.IsDismissed = true;
|
||||
n.IsAnimatingOut = true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user