mirror of
https://github.com/MindWorkAI/AI-Studio.git
synced 2025-04-28 08:19:47 +00:00
Removed indexer from language plugin classes
This commit is contained in:
parent
2ba4789b31
commit
7a56ec6705
@ -20,15 +20,6 @@ public interface ILanguagePlugin
|
||||
/// <returns>True if the key exists, false otherwise.</returns>
|
||||
public bool TryGetText(string key, out string value, bool logWarning = false);
|
||||
|
||||
/// <summary>
|
||||
/// Gets the text from the language plugin.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// When the key does not exist, the value will be an empty string.
|
||||
/// </remarks>
|
||||
/// <param name="key">The key to use to get the text.</param>
|
||||
public string this[string key] { get; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets the IETF tag of the language plugin.
|
||||
/// </summary>
|
||||
|
@ -18,8 +18,6 @@ public sealed class NoPluginLanguage : PluginBase, ILanguagePlugin
|
||||
return true;
|
||||
}
|
||||
|
||||
public string this[string key] => string.Empty;
|
||||
|
||||
public string IETFTag => string.Empty;
|
||||
|
||||
public string LangName => string.Empty;
|
||||
|
@ -160,9 +160,6 @@ public sealed class PluginLanguage : PluginBase, ILanguagePlugin
|
||||
return false;
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
public string this[string key] => this.TryGetText(key, out var value) ? value : "string.Empty";
|
||||
|
||||
/// <inheritdoc />
|
||||
public string IETFTag => this.langCultureTag;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user