mirror of
https://github.com/MindWorkAI/AI-Studio.git
synced 2026-11-04 20:27:21 +00:00
Fixed settings which configuration plugins could not manage (#1080)
This commit is contained in:
1 parent
055cce80a0
commit
8642ce2d81
8 files changed
+260
-17
No files matched your search
@@ -14,6 +14,15 @@ public static partial class ManagedConfiguration
|
||||
|
||||
private static ILogger Log => Program.LOGGER_FACTORY.CreateLogger(nameof(ManagedConfiguration));
|
||||
|
||||
/// <summary>
|
||||
/// All registered settings, in no particular order.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// The data classes register their settings when the settings data is created. Once it exists,
|
||||
/// this covers every managed setting, whatever its type.
|
||||
/// </remarks>
|
||||
internal static IEnumerable<ConfigMetaBase> RegisteredSettings => METADATA.Values.OfType<ConfigMetaBase>();
|
||||
|
||||
/// <summary>
|
||||
/// Attempts to retrieve the configuration metadata for a given configuration selection and
|
||||
/// property expression (enum-based).
|
||||
@@ -325,11 +334,8 @@ public static partial class ManagedConfiguration
|
||||
var wasChanged = false;
|
||||
var registeredSettingNames = new HashSet<string>(StringComparer.Ordinal);
|
||||
|
||||
foreach (var config in METADATA.Values)
|
||||
foreach (var configMeta in RegisteredSettings)
|
||||
{
|
||||
if (config is not ConfigMetaBase configMeta)
|
||||
continue;
|
||||
|
||||
registeredSettingNames.Add(configMeta.SettingName);
|
||||
|
||||
//
|
||||
|
||||
Reference in new issue
Block a user