Merge remote-tracking branch 'origin/ConnectPro_v1.1' into ConnectPro_v1.2

# Conflicts:
#	CHANGELOG.md
#	ICD.Common.Utils/Properties/AssemblyInfo.cs
This commit is contained in:
Chris Cameron
2020-04-30 15:16:23 -04:00
5 changed files with 35 additions and 10 deletions

View File

@@ -1,4 +1,5 @@
using ICD.Common.Utils.Services;
using System.Globalization;
using ICD.Common.Utils.Services;
using ICD.Common.Utils.Services.Logging;
#if SIMPLSHARP
using System;
@@ -99,7 +100,7 @@ namespace ICD.Common.Utils
/// Gets the date that the firmware was updated.
/// </summary>
[PublicAPI]
public static string ModelVersionDate
public static DateTime ModelVersionDate
{
get
{
@@ -107,12 +108,12 @@ namespace ICD.Common.Utils
Match match = regex.Match(VersionResult);
if (match.Success)
return match.Groups["date"].Value;
return DateTime.ParseExact(match.Groups["date"].Value, "MMM dd yyyy", CultureInfo.InvariantCulture).ToUniversalTime();
ServiceProvider.TryGetService<ILoggerService>()
.AddEntry(eSeverity.Warning, "Unable to get model version date from \"{0}\"", VersionResult);
return string.Empty;
return DateTime.MinValue;
}
}