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:
@@ -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;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user