refactor: 增加 static 关键字

This commit is contained in:
Argo-Cloud 2021-01-02 21:45:48 +08:00
parent 23c9db651c
commit 534a3a80f0
1 changed files with 1 additions and 1 deletions

View File

@ -13,7 +13,7 @@ namespace Microsoft.Extensions.DependencyInjection
public static class DisplayNamesExtensions
{
private static ConcurrentDictionary<(Type ModelType, string FieldName), string> _displayNameCache = new ConcurrentDictionary<(Type, string), string>();
private static readonly ConcurrentDictionary<(Type ModelType, string FieldName), string> _displayNameCache = new ConcurrentDictionary<(Type, string), string>();
/// <summary>
/// 向系统中加入实体类显示名称字典