fix: null temp plugins after use

This commit is contained in:
goat 2021-05-01 18:32:25 +02:00
parent 500bd926f8
commit 92b825104e
No known key found for this signature in database
GPG key ID: F18F057873895461

View file

@ -43,7 +43,7 @@ namespace Dalamud.Interface.Scratchpad
if (existingScratch.Value != null)
{
existingScratch.Value.Dispose();
this.loadedScratches.Remove(existingScratch.Key);
this.loadedScratches[existingScratch.Key] = null;
}
var code = doc.IsMacro ? this.MacroProcessor.Process(doc.Content) : doc.Content;
@ -76,7 +76,7 @@ namespace Dalamud.Interface.Scratchpad
plugin.Initialize(pi);
this.loadedScratches.Add(doc.Id, plugin);
this.loadedScratches[doc.Id] = plugin;
return ScratchLoadStatus.Success;
}
catch (CompilationErrorException ex)