Error logging exception
davidjrh opened this issue · 2 comments
davidjrh commented
In some cases, if a developer sets a property while logging an exception and the property is one of the already being logged by the provider, an exception occurs:
DotNetNuke.Services.Log.EventLog.LogController - System.ArgumentException: An item with the same key has already been added.
at System.ThrowHelper.ThrowArgumentException(ExceptionResource resource)
at System.Collections.Generic.Dictionary`2.Insert(TKey key, TValue value, Boolean add)
at DotNetNuke.Monitoring.AppInsights.AppInsightsLoggingProvider.GetProperties(LogInfo logInfo)
at DotNetNuke.Monitoring.AppInsights.AppInsightsLoggingProvider.AddLog(LogInfo logInfo)
at DotNetNuke.Services.Log.EventLog.LogController.AddLog(LogInfo logInfo)
davidjrh commented
Solved
davidjrh commented
Added a second fix