feat: add error handling and logging to SendAtcFullMessageObject method in IDialerCallStatusMessenger

This commit is contained in:
Neil Dorin 2026-08-12 10:59:01 -06:00
parent 7fca4d74bf
commit 2588b81f0d

View file

@ -2,6 +2,7 @@
using System.Linq; using System.Linq;
using Newtonsoft.Json.Linq; using Newtonsoft.Json.Linq;
using PepperDash.Core; using PepperDash.Core;
using PepperDash.Core.Logging;
using PepperDash.Essentials.Devices.Common.AudioCodec; using PepperDash.Essentials.Devices.Common.AudioCodec;
using PepperDash.Essentials.Devices.Common.Codec; using PepperDash.Essentials.Devices.Common.Codec;
@ -102,6 +103,8 @@ namespace PepperDash.Essentials.AppServer.Messengers
/// </summary> /// </summary>
/// <returns></returns> /// <returns></returns>
private void SendAtcFullMessageObject(string id = null) private void SendAtcFullMessageObject(string id = null)
{
try
{ {
var info = Codec.CodecInfo; var info = Codec.CodecInfo;
@ -111,10 +114,15 @@ namespace PepperDash.Essentials.AppServer.Messengers
calls = Codec.ActiveCalls, calls = Codec.ActiveCalls,
info = new info = new
{ {
phoneNumber = info.PhoneNumber phoneNumber = info?.PhoneNumber
} }
}), id }), id
); );
} }
catch (Exception ex)
{
this.LogError(ex, "Error sending dialer call status full message");
}
}
} }
} }