using Umbraco.Cms.Core.Events; using Umbraco.Cms.Core.Features; using Umbraco.Cms.Core.Notifications; namespace Umbraco.Cms.Web.BackOffice.ModelsBuilder; /// /// Used in conjunction with /// internal class DisableModelsBuilderNotificationHandler : INotificationHandler { private readonly UmbracoFeatures _features; public DisableModelsBuilderNotificationHandler(UmbracoFeatures features) => _features = features; /// /// Handles the notification to disable MB controller features /// public void Handle(UmbracoApplicationStartingNotification notification) => // disable the embedded dashboard controller _features.Disabled.Controllers.Add(); }