Skip to content

Commit edab371

Browse files
authored
Merge pull request #13 from steveglen/master
Handle deserialisation of <nil/> data type
2 parents 4a792b3 + edb6250 commit edab371

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

Kveer.XmlRPC/XmlRpcSerializer.cs

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -647,8 +647,14 @@ object ParseValue(
647647
parsedType = typeof(DateTime);
648648
parsedArrayType = typeof(DateTime[]);
649649
}
650+
else if (node.Name == "nil")
651+
{
652+
retObj = null;
653+
parsedType = null;
654+
parsedArrayType = null;
655+
}
650656
else
651-
{
657+
{
652658
throw new XmlRpcInvalidXmlRpcException(
653659
"Invalid value element: <" + node.Name + ">");
654660
}

0 commit comments

Comments
 (0)