Stream custom live channels using your own media
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

24 lines
603 B

using System.Collections.Concurrent;
using ErsatzTV.Core.Interfaces.Troubleshooting;
namespace ErsatzTV.Core.Troubleshooting;
public class TroubleshootingNotifier : ITroubleshootingNotifier
{
private readonly ConcurrentDictionary<Guid, bool> _failedSessions = new();
public bool IsFailed(Guid sessionId)
{
return _failedSessions.TryGetValue(sessionId, out _);
}
public void NotifyFailed(Guid sessionId)
{
_failedSessions[sessionId] = true;
}
public void RemoveSession(Guid sessionId)
{
_failedSessions.TryRemove(sessionId, out _);
}
}