Reduce some allocations with the magic of spans etc.

This commit is contained in:
cvium
2021-04-30 15:09:36 +02:00
parent eeb5d4bd1e
commit 608cba817c
9 changed files with 267 additions and 95 deletions

View File

@@ -315,10 +315,9 @@ namespace Emby.Server.Implementations.Localization
}
const string Prefix = "Core";
var key = Prefix + culture;
return _dictionaries.GetOrAdd(
key,
culture,
f => GetDictionary(Prefix, culture, DefaultCulture + ".json").GetAwaiter().GetResult());
}