Nested Content with ModelsBuilder disabled will throw a null-reference exception.
The fix is to check if the `Current` instance as a `Value`. For more details, see ticket: http://issues.umbraco.org/issue/U4-10260
This commit is contained in:
@@ -108,7 +108,7 @@ namespace Umbraco.Web.PropertyEditors.ValueConverters
|
||||
i,
|
||||
preview);
|
||||
|
||||
if (PublishedContentModelFactoryResolver.HasCurrent)
|
||||
if (PublishedContentModelFactoryResolver.HasCurrent && PublishedContentModelFactoryResolver.Current.HasValue)
|
||||
{
|
||||
// Let the current model factory create a typed model to wrap our model
|
||||
content = PublishedContentModelFactoryResolver.Current.Factory.CreateModel(content);
|
||||
|
||||
Reference in New Issue
Block a user