diff --git a/apps/public-web/src/EShopOnAbp.PublicWeb/EShopOnAbp.PublicWeb.csproj b/apps/public-web/src/EShopOnAbp.PublicWeb/EShopOnAbp.PublicWeb.csproj index 5effde24..a9c12dc4 100644 --- a/apps/public-web/src/EShopOnAbp.PublicWeb/EShopOnAbp.PublicWeb.csproj +++ b/apps/public-web/src/EShopOnAbp.PublicWeb/EShopOnAbp.PublicWeb.csproj @@ -28,8 +28,6 @@ - - diff --git a/gateways/web-public/src/EShopOnAbp.WebPublicGateway/EShopOnAbpWebPublicGatewayModule.cs b/gateways/web-public/src/EShopOnAbp.WebPublicGateway/EShopOnAbpWebPublicGatewayModule.cs index 86d0fb5d..95ca4f5c 100644 --- a/gateways/web-public/src/EShopOnAbp.WebPublicGateway/EShopOnAbpWebPublicGatewayModule.cs +++ b/gateways/web-public/src/EShopOnAbp.WebPublicGateway/EShopOnAbpWebPublicGatewayModule.cs @@ -38,6 +38,7 @@ namespace EShopOnAbp.WebPublicGateway } app.UseCorrelationId(); + app.UseAbpSerilogEnrichers(); app.UseSwagger(); app.UseSwaggerUI(options => { @@ -66,10 +67,8 @@ namespace EShopOnAbp.WebPublicGateway // options.OAuthClientSecret("1q2w3e*"); } }); - app.UseAbpSerilogEnrichers(); app.MapWhen( - ctx => ctx.Request.Path.ToString().StartsWith("/api/abp/api-definition") || - ctx.Request.Path.ToString().TrimEnd('/').Equals(""), + ctx => ctx.Request.Path.ToString().TrimEnd('/').Equals(""), app2 => { app2.UseRouting(); diff --git a/gateways/web/src/EShopOnAbp.WebGateway/EShopOnAbpWebGatewayModule.cs b/gateways/web/src/EShopOnAbp.WebGateway/EShopOnAbpWebGatewayModule.cs index b7b2ee1f..b933506b 100644 --- a/gateways/web/src/EShopOnAbp.WebGateway/EShopOnAbpWebGatewayModule.cs +++ b/gateways/web/src/EShopOnAbp.WebGateway/EShopOnAbpWebGatewayModule.cs @@ -57,6 +57,7 @@ namespace EShopOnAbp.WebGateway } app.UseCorrelationId(); + app.UseAbpSerilogEnrichers(); app.UseCors(); app.UseSwagger(); app.UseSwaggerUI(options => @@ -82,10 +83,8 @@ namespace EShopOnAbp.WebGateway options.OAuthClientSecret(configuration["AuthServer:SwaggerClientSecret"]); } }); - app.UseAbpSerilogEnrichers(); app.MapWhen( - ctx => ctx.Request.Path.ToString().StartsWith("/api/abp/api-definition") || - ctx.Request.Path.ToString().TrimEnd('/').Equals(""), + ctx => ctx.Request.Path.ToString().TrimEnd('/').Equals(""), app2 => { app2.UseRouting();