chore: only expose manifests as interfaces

This commit is contained in:
goat 2023-06-28 12:27:50 +02:00
parent a88151de7f
commit 98bdec1e34
No known key found for this signature in database
GPG key ID: 49E2AA8C6A76498B
16 changed files with 257 additions and 181 deletions

View file

@ -25,7 +25,7 @@ internal static class BugBait
/// <param name="reporter">The reporter name.</param>
/// <param name="includeException">Whether or not the most recent exception to occur should be included in the report.</param>
/// <returns>A <see cref="Task"/> representing the asynchronous operation.</returns>
public static async Task SendFeedback(PluginManifest plugin, bool isTesting, string content, string reporter, bool includeException)
public static async Task SendFeedback(IPluginManifest plugin, bool isTesting, string content, string reporter, bool includeException)
{
if (content.IsNullOrWhitespace())
return;

View file

@ -67,7 +67,7 @@ public static class Troubleshooting
{
var payload = new TroubleshootingPayload
{
LoadedPlugins = pluginManager?.InstalledPlugins?.Select(x => x.Manifest)?.OrderByDescending(x => x.InternalName).ToArray(),
LoadedPlugins = pluginManager?.InstalledPlugins?.Select(x => x.Manifest as LocalPluginManifest)?.OrderByDescending(x => x.InternalName).ToArray(),
PluginStates = pluginManager?.InstalledPlugins?.Where(x => !x.IsDev).ToDictionary(x => x.Manifest.InternalName, x => x.IsBanned ? "Banned" : x.State.ToString()),
EverStartedLoadingPlugins = pluginManager?.InstalledPlugins.Where(x => x.HasEverStartedLoad).Select(x => x.InternalName).ToList(),
DalamudVersion = Util.AssemblyVersion,