OrchardCMS / Orchard

Orchard is a free, open source, community-focused Content Management System built on the ASP.NET MVC platform.
https://orchardproject.net
BSD 3-Clause "New" or "Revised" License
2.37k stars 1.12k forks source link

ContentMenuItem is displayed inside navigation even if ContentItem isn't published #8652

Closed AndreaPiovanelli closed 1 year ago

AndreaPiovanelli commented 1 year ago

https://github.com/OrchardCMS/Orchard/blob/babe1d665d8d5960120ac486455ee5fcd85ad022/src/Orchard.Web/Core/Navigation/Services/DefaultMenuProvider.cs#L36

When adding a ContentMenuItem to a menu and selecting a unpublished ContentItem, MenuProvider adds it to the builder as well, causing it to be shown at front end and resulting in 404 errors.