Press Ctrl / CMD + C to copy this to your clipboard.
This post will be reported to the moderators as potential spam to be looked at
Getting this log error repeatedly on a 7,10.4 site. Any ideas what might be causing it?
ERROR Umbraco.Core.Dynamics.DynamicInstanceHelper - An error occurred finding and executing extension method "IsDescendantOrSelf" for type "Umbraco.Web.Models.DynamicPublishedContent". Types searched for extension methods were Umbraco.Web.Models.DynamicPublishedContent.
System.MissingMethodException: Method 'Umbraco.Web.Models.DynamicPublishedContent.IsDescendantOrSelf' not found.
at Umbraco.Core.Dynamics.DynamicInstanceHelper.FindAndExecuteExtensionMethod[T](IRuntimeCacheProvider runtimeCache, T thisObject, Object args, String name, IEnumerable`1 findMethodsOnTypes)
The problem is that you are calling extension methods on a dynamic. Please, find the place where it's used and rewrite it to strongly typed.
Can you share the code? and maybe you have some questions?
Hey Alex, the issue is there are dynamics being used in various places and the error log doesn't say which partial is throwing the error so I'm not sure where to begin with debugging.
Can you use Visual Studio? Just do a search over the code for "IsDescendantOrSelf" method.
There's lots of it. Here's an example to switch a partial based on the parent page. We have to do this for various reasons on this particular site. Is there a better way?
You need to replace all places with this code:
is working on a reply...
Write your reply to:
Image will be uploaded when post is submitted