mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2026-02-09 09:16:41 +08:00
#17597: Fixing wrong feature name in notification when enabling/disabling a feature
--HG-- branch : 1.x
This commit is contained in:
@@ -72,7 +72,8 @@ namespace Orchard.Modules.Services {
|
||||
/// <param name="force">Boolean parameter indicating if the feature should enable it's dependencies if required or fail otherwise.</param>
|
||||
public void EnableFeatures(IEnumerable<string> featureIds, bool force) {
|
||||
foreach (string featureId in _featureManager.EnableFeatures(featureIds, force)) {
|
||||
Services.Notifier.Information(T("{0} was enabled", featureId));
|
||||
var featureName = _featureManager.GetAvailableFeatures().Where(f => f.Id == featureId).First().Name;
|
||||
Services.Notifier.Information(T("{0} was enabled", featureName));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -91,7 +92,8 @@ namespace Orchard.Modules.Services {
|
||||
/// <param name="force">Boolean parameter indicating if the feature should disable the features which depend on it if required or fail otherwise.</param>
|
||||
public void DisableFeatures(IEnumerable<string> featureIds, bool force) {
|
||||
foreach (string featureId in _featureManager.DisableFeatures(featureIds, force)) {
|
||||
Services.Notifier.Information(T("{0} was disabled", featureId));
|
||||
var featureName = _featureManager.GetAvailableFeatures().Where(f => f.Id == featureId).First().Name;
|
||||
Services.Notifier.Information(T("{0} was disabled", featureName));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user