Skip to content

Commit

Permalink
Fix Enum.Parse<T> usage
Browse files Browse the repository at this point in the history
  • Loading branch information
TeodorVecerdi committed Apr 10, 2022
1 parent a071030 commit 6c01a41
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Runtime/Data/DlogObject.cs
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ private CheckTree ParseCheckTree(Edge edge, Dictionary<string, Node> propertyNod
return CheckTree.Property(propertyGuid);
}

BooleanOperation operation = Enum.Parse<BooleanOperation>(node.Type.ToString().Replace("BOOLEAN_", ""));
BooleanOperation operation = (BooleanOperation)Enum.Parse(typeof(BooleanOperation), node.Type.ToString().Replace("BOOLEAN_", ""));
if (node.Type == NodeType.BOOLEAN_NOT) {
Edge notEdge = Edges.FirstOrDefault(e => e.ToNode == node.Guid);
return CheckTree.Unary(operation, ParseCheckTree(notEdge, propertyNodes));
Expand Down

0 comments on commit 6c01a41

Please sign in to comment.