Make tests pass

Quick null check for PublishedPropertyType - we can't create a dummy one from a test due to some internal Umbraco dependencies, and we can't mock it as the relevant properties aren't virtual, so just adding a quick null check for now.
This commit is contained in:
Tom Fulton
2014-04-24 23:11:47 -06:00
parent 7a29683008
commit ea017fa6cd
@@ -39,8 +39,9 @@ namespace Archetype.Umbraco.PropertyConverters
if (!sourceString.DetectIsJson())
return defaultValue;
var archetype = new ArchetypeHelper().DeserializeJsonToArchetype(source.ToString(), propertyType.DataTypeId);
var archetype = new ArchetypeHelper().DeserializeJsonToArchetype(source.ToString(),
(propertyType != null ? propertyType.DataTypeId : -1));
return archetype;
}