mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2025-09-19 18:27:55 +08:00
Fix concurrency issue with "T" injection
--HG-- branch : dev
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
namespace Orchard.Localization {
|
||||
public interface IText : ISingletonDependency {
|
||||
public interface IText {
|
||||
LocalizedString Get(string textHint, params object[] args);
|
||||
}
|
||||
}
|
@@ -1,4 +1,5 @@
|
||||
using System;
|
||||
using System.Collections.Concurrent;
|
||||
using System.Collections.Generic;
|
||||
using System.Reflection;
|
||||
using Autofac;
|
||||
@@ -10,7 +11,7 @@ namespace Orchard.Localization {
|
||||
private readonly IDictionary<string, Localizer> _localizerCache;
|
||||
|
||||
public LocalizationModule() {
|
||||
_localizerCache = new Dictionary<string, Localizer>();
|
||||
_localizerCache = new ConcurrentDictionary<string, Localizer>();
|
||||
}
|
||||
|
||||
protected override void Load(ContainerBuilder builder) {
|
||||
|
Reference in New Issue
Block a user