We need to explicty call UseAntiforgery, otherwise it is called automatically before our middleware that will lead to UmbracoRouteValueTransformer being called instead of static file middleware.

This commit is contained in:
Bjarke Berg
2023-09-19 10:22:42 +02:00
parent 96397adf1f
commit a133a4b57b

View File

@@ -89,6 +89,8 @@ public class UmbracoApplicationBuilder : IUmbracoApplicationBuilder, IUmbracoEnd
AppBuilder.UseAuthentication();
AppBuilder.UseAuthorization();
AppBuilder.UseAntiforgery();
// This must come after auth because the culture is based on the auth'd user
AppBuilder.UseRequestLocalization();