diff --git a/src/PepperDash.Essentials.MobileControl.Messengers/Messengers/CurrentSourcesMessenger.cs b/src/PepperDash.Essentials.MobileControl.Messengers/Messengers/CurrentSourcesMessenger.cs index 01763b59..8badfdf6 100644 --- a/src/PepperDash.Essentials.MobileControl.Messengers/Messengers/CurrentSourcesMessenger.cs +++ b/src/PepperDash.Essentials.MobileControl.Messengers/Messengers/CurrentSourcesMessenger.cs @@ -14,11 +14,21 @@ namespace PepperDash.Essentials.AppServer.Messengers public class CurrentSourcesMessenger : MessengerBase { private readonly ICurrentSources sourceDevice; + + /// + /// Initializes a new instance of the class. + /// + /// The key. + /// The message path. + /// The device. public CurrentSourcesMessenger(string key, string messagePath, ICurrentSources device) : base(key, messagePath, device as IKeyName) { sourceDevice = device; } + /// + /// Registers the actions for the messenger. + /// protected override void RegisterActions() { base.RegisterActions(); @@ -55,7 +65,6 @@ namespace PepperDash.Essentials.AppServer.Messengers /// Gets or sets the CurrentSourceKey /// [JsonProperty("currentSourceKey", NullValueHandling = NullValueHandling.Ignore)] - [JsonConverter(typeof(StringEnumConverter))] public Dictionary CurrentSourceKeys { get; set; } diff --git a/src/PepperDash.Essentials.MobileControl/MobileControlSystemController.cs b/src/PepperDash.Essentials.MobileControl/MobileControlSystemController.cs index 3c853c01..da6349db 100644 --- a/src/PepperDash.Essentials.MobileControl/MobileControlSystemController.cs +++ b/src/PepperDash.Essentials.MobileControl/MobileControlSystemController.cs @@ -728,6 +728,8 @@ namespace PepperDash.Essentials var messenger = new CurrentSourcesMessenger($"{device.Key}-currentSources-{Key}", $"/device/{device.Key}", currentSources); AddDefaultDeviceMessenger(messenger); + + messengerAdded = true; } if (device is ISwitchedOutput switchedDevice)