fixed plugin startup issue

This commit is contained in:
PaulKoudelka 2026-06-02 15:49:05 +02:00
parent bd9597c706
commit 6c67083c3a
2 changed files with 9 additions and 1 deletions

View File

@ -5,7 +5,7 @@ public class I18N : ILang
public static readonly I18N I = new();
private static readonly ILogger<I18N> LOG = Program.LOGGER_FACTORY.CreateLogger<I18N>();
private ILanguagePlugin? language = PluginFactory.BaseLanguage;
private ILanguagePlugin? language;
private I18N()
{

View File

@ -85,6 +85,14 @@ public abstract partial class PluginBase : IPluginMetadata
if(!string.IsNullOrWhiteSpace(parseError))
issues.Add(parseError);
if (this is NoPlugin or NoPluginLanguage)
{
this.IsInternal = isInternal;
this.IconSVG = string.Empty;
this.baseIssues = issues;
return;
}
// Notice: when no icon is specified, the default icon will be used.
this.TryInitIconSVG(out _, out var iconSVG);
this.IconSVG = iconSVG;