diff --git a/ICD.Common.Utils/Extensions/JsonReaderExtensions.cs b/ICD.Common.Utils/Extensions/JsonReaderExtensions.cs index 1a5f128..808b25c 100644 --- a/ICD.Common.Utils/Extensions/JsonReaderExtensions.cs +++ b/ICD.Common.Utils/Extensions/JsonReaderExtensions.cs @@ -213,8 +213,12 @@ namespace ICD.Common.Utils.Extensions if (extends == null) throw new ArgumentNullException("extends"); +#if SIMPLSHARP string stringValue = extends.GetValueAsString(); return JsonUtils.ParseDateTime(stringValue); +#else + return (DateTime)extends.Value; +#endif } } } diff --git a/ICD.Common.Utils/Json/JsonUtils.cs b/ICD.Common.Utils/Json/JsonUtils.cs index 105b9c4..73e7140 100644 --- a/ICD.Common.Utils/Json/JsonUtils.cs +++ b/ICD.Common.Utils/Json/JsonUtils.cs @@ -39,7 +39,11 @@ namespace ICD.Common.Utils.Json if (token == null) throw new ArgumentNullException("token"); +#if SIMPLSHARP return ParseDateTime((string)token); +#else + return (DateTime)token; +#endif } ///