From deaf26109b970da33a034d24e0603a273cf8518f Mon Sep 17 00:00:00 2001 From: Poornima Nayar Date: Tue, 15 May 2018 19:33:36 +0100 Subject: [PATCH] check for recursive value --- src/Umbraco.Web/umbraco.presentation/item.cs | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/src/Umbraco.Web/umbraco.presentation/item.cs b/src/Umbraco.Web/umbraco.presentation/item.cs index 1edc6cca17..33150d6187 100644 --- a/src/Umbraco.Web/umbraco.presentation/item.cs +++ b/src/Umbraco.Web/umbraco.presentation/item.cs @@ -66,8 +66,12 @@ namespace umbraco if (publishedContent == null) { - var recursiveVal = GetRecursiveValueLegacy(elements); - _fieldContent = recursiveVal.IsNullOrWhiteSpace() ? _fieldContent : recursiveVal; + if (recursive) + { + var recursiveVal = GetRecursiveValueLegacy(elements); + _fieldContent = recursiveVal.IsNullOrWhiteSpace() ? _fieldContent : recursiveVal; + } + } //check for published content and get its value using that @@ -222,4 +226,4 @@ namespace umbraco } } } -} \ No newline at end of file +}