Script Engines now removed from manager when closed (#2706)

Signed-off-by: Jonathan Gilbert <jpg@trillica.com>
pull/2708/head
Jonathan Gilbert 2022-01-25 08:12:02 +00:00 committed by GitHub
parent f79d17f864
commit 59bc10a2af
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -198,7 +198,7 @@ public class ScriptEngineManagerImpl implements ScriptEngineManager {
@Override
public void removeEngine(String engineIdentifier) {
ScriptEngineContainer container = loadedScriptEngineInstances.get(engineIdentifier);
ScriptEngineContainer container = loadedScriptEngineInstances.remove(engineIdentifier);
if (container != null) {
ScriptEngine scriptEngine = container.getScriptEngine();
if (scriptEngine instanceof Invocable) {