Skip to content

Commit

Permalink
🐛 Properly register new device states to the dictionary in PowerService.
Browse files Browse the repository at this point in the history
  • Loading branch information
hexawyz committed Aug 18, 2024
1 parent 18b0a00 commit 381e76f
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions Exo.Service.Core/PowerService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -377,6 +377,7 @@ private async ValueTask HandleArrivalAsync(DeviceWatchNotification notification,
if (!_deviceStates.TryGetValue(notification.DeviceInformation.Id, out var deviceState))
{
deviceState = new(this, _devicesConfigurationContainer.GetContainer(notification.DeviceInformation.Id), notification.DeviceInformation.Id, default);
_deviceStates.TryAdd(notification.DeviceInformation.Id, deviceState);
shouldPersistInformation = true;
}

Expand Down

0 comments on commit 381e76f

Please sign in to comment.