diff --git a/src/main/java/org/lsc/utils/ScriptingEvaluator.java b/src/main/java/org/lsc/utils/ScriptingEvaluator.java index ca05f946..b69c3b88 100644 --- a/src/main/java/org/lsc/utils/ScriptingEvaluator.java +++ b/src/main/java/org/lsc/utils/ScriptingEvaluator.java @@ -91,8 +91,8 @@ else if ("graal.js".equals(name)) { defaultImplementation = Optional.of(graaljsevaluator); } else { - defaultImplementation = Optional.ofNullable(instancesTypeCache.get("js")) - .or(() -> Optional.ofNullable(instancesTypeCache.get("rjs"))); + defaultImplementation = Optional.ofNullable(Optional.ofNullable(instancesTypeCache.get("js")) + .orElse(instancesTypeCache.get("rjs"))); } }