From 714e9e03196adba93e8ae7798bca6d4518a10595 Mon Sep 17 00:00:00 2001 From: goaaats Date: Wed, 20 Mar 2024 23:28:14 +0100 Subject: [PATCH] pm: don't throw if there are no valid versions for a plugin --- Dalamud/Plugin/Internal/PluginManager.cs | 20 +++++++++++++++++--- 1 file changed, 17 insertions(+), 3 deletions(-) diff --git a/Dalamud/Plugin/Internal/PluginManager.cs b/Dalamud/Plugin/Internal/PluginManager.cs index 792294851..7c56d612e 100644 --- a/Dalamud/Plugin/Internal/PluginManager.cs +++ b/Dalamud/Plugin/Internal/PluginManager.cs @@ -470,10 +470,18 @@ internal partial class PluginManager : IInternalDisposableService try { var dllFile = new FileInfo(Path.Combine(versionDir.FullName, $"{pluginDir.Name}.dll")); - var manifestFile = LocalPluginManifest.GetManifestFile(dllFile); - - if (!manifestFile.Exists) + if (!dllFile.Exists) + { + Log.Error("No DLL found for plugin at {Path}", versionDir.FullName); continue; + } + + var manifestFile = LocalPluginManifest.GetManifestFile(dllFile); + if (!manifestFile.Exists) + { + Log.Error("No manifest for plugin at {Path}", dllFile.FullName); + continue; + } var manifest = LocalPluginManifest.Load(manifestFile); if (manifest == null) @@ -494,6 +502,12 @@ internal partial class PluginManager : IInternalDisposableService } this.configuration.QueueSave(); + + if (versionsDefs.Count == 0) + { + Log.Verbose("No versions found for plugin: {Name}", pluginDir.Name); + continue; + } try {