mirror of
https://github.com/ICDSystems/ICD.Common.Utils.git
synced 2026-02-15 20:54:58 +00:00
Fixing bug that prevented enums from being parsed from xml properly
This commit is contained in:
@@ -592,8 +592,8 @@ namespace ICD.Common.Utils.Xml
|
|||||||
public static T? TryReadChildElementContentAsEnum<T>(string xml, string childElement, bool ignoreCase)
|
public static T? TryReadChildElementContentAsEnum<T>(string xml, string childElement, bool ignoreCase)
|
||||||
where T : struct
|
where T : struct
|
||||||
{
|
{
|
||||||
T? output;
|
T output;
|
||||||
return !TryReadChildElementContentAsEnum(xml, childElement, ignoreCase, out output) ? null : output;
|
return TryReadChildElementContentAsEnum(xml, childElement, ignoreCase, out output) ? output : (T?)null;
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|||||||
Reference in New Issue
Block a user