diff --git a/src/Umbraco.Web.Common/Controllers/RenderController.cs b/src/Umbraco.Web.Common/Controllers/RenderController.cs index d1899b5db4d6..2d1d89f47f63 100644 --- a/src/Umbraco.Web.Common/Controllers/RenderController.cs +++ b/src/Umbraco.Web.Common/Controllers/RenderController.cs @@ -112,7 +112,7 @@ public override async Task OnActionExecutionAsync(ActionExecutingContext context /// protected override IActionResult CurrentTemplate(T model) { - if (EnsurePhsyicalViewExists(UmbracoRouteValues.TemplateName) == false) + if (EnsurePhysicalViewExists(UmbracoRouteValues.TemplateName) == false) { // no physical template file was found return new PublishedContentNotFoundResult(UmbracoContext); diff --git a/src/Umbraco.Web.Common/Controllers/UmbracoPageController.cs b/src/Umbraco.Web.Common/Controllers/UmbracoPageController.cs index 4634f4e48add..64cfe3c4ccfa 100644 --- a/src/Umbraco.Web.Common/Controllers/UmbracoPageController.cs +++ b/src/Umbraco.Web.Common/Controllers/UmbracoPageController.cs @@ -79,7 +79,7 @@ protected virtual IPublishedContent? CurrentPage /// protected virtual IActionResult CurrentTemplate(T model) { - if (EnsurePhsyicalViewExists(UmbracoRouteValues.TemplateName) == false) + if (EnsurePhysicalViewExists(UmbracoRouteValues.TemplateName) == false) { throw new InvalidOperationException("No physical template file was found for template " + UmbracoRouteValues.TemplateName); @@ -92,7 +92,14 @@ protected virtual IActionResult CurrentTemplate(T model) /// Ensures that a physical view file exists on disk. /// /// The view name. - protected bool EnsurePhsyicalViewExists(string? template) + [Obsolete("Please use the correctly spelt EnsurePhysicalViewExists method. Scheduled for removal in Umbraco 18.")] + protected bool EnsurePhsyicalViewExists(string? template) => EnsurePhysicalViewExists(template); + + /// + /// Ensures that a physical view file exists on disk. + /// + /// The view name. + protected bool EnsurePhysicalViewExists(string? template) { if (string.IsNullOrWhiteSpace(template)) {