Added exception-handling to all UpdateQueues

This commit is contained in:
DarthAffe committed 2023-03-05 16:34:01 +01:00
1 parent 6e313ea6a1
commit 37e4954583
18 files changed
+222 -97

No files matched your search

@@ -37,10 +37,17 @@ internal class SteelSeriesDeviceUpdateQueue : UpdateQueue
protected override void OnUpdate(object? sender, CustomUpdateData customData)
{
if (customData[CustomUpdateDataIndex.HEARTBEAT] as bool? ?? false)
SteelSeriesSDK.SendHeartbeat();
else
base.OnUpdate(sender, customData);
try
{
if (customData[CustomUpdateDataIndex.HEARTBEAT] as bool? ?? false)
SteelSeriesSDK.SendHeartbeat();
else
base.OnUpdate(sender, customData);
}
catch (Exception ex)
{
SteelSeriesDeviceProvider.Instance.Throw(ex, true);
}
}
/// <inheritdoc />