Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Dan Evans 599 posts 949 karma points
    Nov 27, 2012 @ 12:59
    Dan Evans
    3

    Bug in Razor version after upgrade to U4.10

    We recently upgraded to U 4.10 and have just noticed the XML sitemap was throwing an error:

    umbraco.MacroEngines.DynamicNodeList' does not contain a definition for 'Count' &nbsp;&nbsp;&nbsp;at CallSite.Target(Closure , CallSite , Object )<br> &nbsp;&nbsp;at ASP._Page_macroScripts_CultivSearchEngineSitemap_cshtml.&lt;&gt;c__DisplayClass27.&lt;ListChildNodes&gt;b__26(TextWriter __razor_helper_writer) in d:\domains\cms47.dedicated.dev.plan9.co.uk\httpdocs\macroScripts\CultivSearchEngineSitemap.cshtml:line 31

    We fixed this by changing line 31 to:

    if (node.Level <= maxLevelForSiteMap && node.ChildrenAsList.Count() > 0)

  • Jason Prothero 414 posts 1222 karma points c-trib
    Dec 16, 2012 @ 04:54
    Jason Prothero
    0

    Thanks for posting this Dan.  Fixed my issue on 4.11.1 as well.

     

     

  • Mikko Vartiainen 9 posts 29 karma points
    Jan 15, 2013 @ 16:34
    Mikko Vartiainen
    0

    The Razor version would't work on my 4.11.2 installation until I changed the line Dan is referring to. Thanks, Dan!

    That should probably be fixed in the original package.

     

  • Dan Evans 599 posts 949 karma points
    Jan 15, 2013 @ 16:37
    Dan Evans
    101

    You are welcome.

  • Michiel 30 posts 61 karma points
    Feb 04, 2013 @ 11:22
    Michiel
    0

    Thx, this fixed it in 4.11.4 aswel.

  • Proxicode 115 posts 289 karma points
    Apr 20, 2015 @ 17:52
    Proxicode
    0

    Still a valid fix in Umbraco 7.2 - Thanks Dan!

Please Sign in or register to post replies

Write your reply to:

Draft