Skip to content

Commit cc283fb

Browse files
committed
Merge pull request restsharp#259 from Dharun/patch-1
XmlAttributeDeserializer crashes if value == ""
2 parents 054adce + c68de9d commit cc283fb

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

RestSharp/Deserializers/XmlAttributeDeserializer.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ private void Map(object x, XElement root)
109109

110110
var value = GetValueFromXml(root, name, isAttribute);
111111

112-
if (value == null)
112+
if (value == null || value == string.Empty)
113113
{
114114
// special case for inline list items
115115
if (type.IsGenericType)

0 commit comments

Comments
 (0)