Fix U4-2711 add Null Check to ToXMl method
Fixes Object reference not set to an instance of an object. at umbraco.editorControls.imagecropper.DataTypeData.ToXMl(XmlDocument data)
This commit is contained in:
@@ -8,7 +8,7 @@ namespace umbraco.editorControls.imagecropper
|
||||
|
||||
public override XmlNode ToXMl(XmlDocument data)
|
||||
{
|
||||
if (Value.ToString() != "") {
|
||||
if (Value!=null && Value.ToString() != "") {
|
||||
XmlDocument xd = new XmlDocument();
|
||||
xd.LoadXml(Value.ToString());
|
||||
return data.ImportNode(xd.DocumentElement, true);
|
||||
|
||||
Reference in New Issue
Block a user