Skip to content

Commit

Permalink
Fix: Emit the actual duration of an AniDB ban
Browse files Browse the repository at this point in the history
  • Loading branch information
fearnlj01 authored and da3dsoul committed Apr 3, 2024
1 parent 54c3e43 commit 975b7b9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Shoko.Server/API/SignalR/Aggregate/AniDBEmitter.cs
Original file line number Diff line number Diff line change
Expand Up @@ -44,14 +44,14 @@ public override object GetInitialMessage()
UpdateType = UpdateType.UDPBan,
UpdateTime = UDPHandler.BanTime ?? DateTime.Now,
Value = UDPHandler.IsBanned,
PauseTimeSecs = TimeSpan.FromHours(UDPHandler.BanTimerResetLength).Seconds
PauseTimeSecs = (int)TimeSpan.FromHours(UDPHandler.BanTimerResetLength).TotalSeconds
},
new()
{
UpdateType = UpdateType.HTTPBan,
UpdateTime = HttpHandler.BanTime ?? DateTime.Now,
Value = HttpHandler.IsBanned,
PauseTimeSecs = TimeSpan.FromHours(HttpHandler.BanTimerResetLength).Seconds
PauseTimeSecs = (int)TimeSpan.FromHours(HttpHandler.BanTimerResetLength).TotalSeconds
}
};
}
Expand Down

0 comments on commit 975b7b9

Please sign in to comment.