Server Error in '/' Application.

Object reference not set to an instance of an object.

Description: An unhandled exception occurred.

Exception Details: System.NullReferenceException: Object reference not set to an instance of an object.

Source Error:


Line 18:       foreach (BaseVariantField variantField in Model.VariantFields)
Line 19:       {
Line 20:         @Html.RenderingVariants().RenderVariant(variantField, Model.Item, Model.RenderingWebEditingParams, Model)
Line 21:       }
Line 22:     }

Source File: c:\home\site\wwwroot\Views\LW\SimpleHero\SimpleHero.cshtml    Line: 20

Stack Trace:


[NullReferenceException: Object reference not set to an instance of an object.]
   Sitecore.XA.Foundation.Scriban.Pipelines.RenderVariantField.RenderScriban.RenderField(RenderVariantFieldArgs args) +274
   Sitecore.XA.Foundation.Variants.Abstractions.Pipelines.RenderVariantField.RenderVariantFieldProcessor.Process(RenderVariantFieldArgs args) +131
   (Object , Object ) +8
   Sitecore.Pipelines.CorePipeline.Run(PipelineArgs args) +489
   Sitecore.Pipelines.DefaultCorePipelineManager.Run(String pipelineName, PipelineArgs args, String pipelineDomain, Boolean failIfNotExists) +235
   Sitecore.Pipelines.DefaultCorePipelineManager.Run(String pipelineName, PipelineArgs args, String pipelineDomain) +21
   Sitecore.XA.Foundation.RenderingVariants.Pipelines.RenderVariantField.RenderSection.RenderField(RenderVariantFieldArgs args) +381
   Sitecore.XA.Foundation.Variants.Abstractions.Pipelines.RenderVariantField.RenderVariantFieldProcessor.Process(RenderVariantFieldArgs args) +131
   (Object , Object ) +8
   Sitecore.Pipelines.CorePipeline.Run(PipelineArgs args) +489
   Sitecore.Pipelines.DefaultCorePipelineManager.Run(String pipelineName, PipelineArgs args, String pipelineDomain, Boolean failIfNotExists) +235
   Sitecore.Pipelines.DefaultCorePipelineManager.Run(String pipelineName, PipelineArgs args, String pipelineDomain) +21
   Sitecore.XA.Foundation.RenderingVariants.Pipelines.RenderVariantField.RenderSection.RenderField(RenderVariantFieldArgs args) +381
   Sitecore.XA.Foundation.Variants.Abstractions.Pipelines.RenderVariantField.RenderVariantFieldProcessor.Process(RenderVariantFieldArgs args) +131
   (Object , Object ) +8
   Sitecore.Pipelines.CorePipeline.Run(PipelineArgs args) +489
   Sitecore.Pipelines.DefaultCorePipelineManager.Run(String pipelineName, PipelineArgs args, String pipelineDomain, Boolean failIfNotExists) +235
   Sitecore.Pipelines.DefaultCorePipelineManager.Run(String pipelineName, PipelineArgs args, String pipelineDomain) +21
   Sitecore.XA.Foundation.Variants.Abstractions.Renderers.VariantRenderer.RenderVariantField(BaseVariantField variant, Item item, Dictionary`2 parameters) +239
   Sitecore.XA.Foundation.RenderingVariants.Extensions.RenderingVariantsExtensions.RenderVariant(BaseVariantField variantField, Item item, RenderingWebEditingParams parameters, Object model, Func`3 hrefOverrideFunc) +206
   ASP._Page_Views_LW_SimpleHero_SimpleHero_cshtml.Execute() in c:\home\site\wwwroot\Views\LW\SimpleHero\SimpleHero.cshtml:20
   System.Web.WebPages.WebPageBase.ExecutePageHierarchy() +251
   System.Web.Mvc.WebViewPage.ExecutePageHierarchy() +147
   System.Web.WebPages.WebPageBase.ExecutePageHierarchy(WebPageContext pageContext, TextWriter writer, WebPageRenderingBase startPage) +121
   System.Web.Mvc.ViewResultBase.ExecuteResult(ControllerContext context) +377
   System.Web.Mvc.ControllerActionInvoker.InvokeActionResultFilterRecursive(IList`1 filters, Int32 filterIndex, ResultExecutingContext preContext, ControllerContext controllerContext, ActionResult actionResult) +90
   System.Web.Mvc.ControllerActionInvoker.InvokeActionResultFilterRecursive(IList`1 filters, Int32 filterIndex, ResultExecutingContext preContext, ControllerContext controllerContext, ActionResult actionResult) +795
   System.Web.Mvc.ControllerActionInvoker.InvokeActionResultFilterRecursive(IList`1 filters, Int32 filterIndex, ResultExecutingContext preContext, ControllerContext controllerContext, ActionResult actionResult) +795
   System.Web.Mvc.ControllerActionInvoker.InvokeActionResultWithFilters(ControllerContext controllerContext, IList`1 filters, ActionResult actionResult) +81
   System.Web.Mvc.ControllerActionInvoker.InvokeAction(ControllerContext controllerContext, String actionName) +698


Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.8.4690.0