Skip to content

Commit 44ddf7a

Browse files
ZeegaanNikolaj Geisle
andauthored
Add extra check (#12075)
Co-authored-by: Nikolaj Geisle <[email protected]>
1 parent 0c7ef06 commit 44ddf7a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Umbraco.Web.Common/Extensions/ControllerExtensions.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ public static async Task<AuthenticateResult> AuthenticateBackOfficeAsync(this Co
2424
/// <returns></returns>
2525
public static string GetControllerName(Type controllerType)
2626
{
27-
if (!controllerType.Name.EndsWith("Controller"))
27+
if (!controllerType.Name.EndsWith("Controller") && !controllerType.Name.EndsWith("Controller`1"))
2828
{
2929
throw new InvalidOperationException("The controller type " + controllerType + " does not follow conventions, MVC Controller class names must be suffixed with the term 'Controller'");
3030
}

0 commit comments

Comments
 (0)