Browse Source

Fix the performance problem of blazor-server

pull/11006/head
liangshiwei 4 years ago
parent
commit
4dfd99b7f7
  1. 5
      framework/src/Volo.Abp.AspNetCore.Mvc.Client/Volo/Abp/AspNetCore/Mvc/Client/MvcCachedApplicationConfigurationClient.cs

5
framework/src/Volo.Abp.AspNetCore.Mvc.Client/Volo/Abp/AspNetCore/Mvc/Client/MvcCachedApplicationConfigurationClient.cs

@ -45,9 +45,8 @@ namespace Volo.Abp.AspNetCore.Mvc.Client
var cacheKey = CreateCacheKey();
var httpContext = HttpContextAccessor?.HttpContext;
if (httpContext != null && !httpContext.WebSockets.IsWebSocketRequest && httpContext.Items[cacheKey] is ApplicationConfigurationDto configuration)
if (httpContext != null && httpContext.Items[cacheKey] is ApplicationConfigurationDto configuration)
{
return configuration;
}
@ -61,7 +60,7 @@ namespace Volo.Abp.AspNetCore.Mvc.Client
}
);
if (httpContext != null && !httpContext.WebSockets.IsWebSocketRequest)
if (httpContext != null)
{
httpContext.Items[cacheKey] = configuration;
}

Loading…
Cancel
Save