Skip to content

Commit

Permalink
Bug 58477 - __javaScript function : Allow use of Nashorn engine for J…
Browse files Browse the repository at this point in the history
…ava8 and upper versions

Take into account sebb feedback
Bugzilla Id: 58477

git-svn-id: https://svn.apache.org/repos/asf/jmeter/trunk@1709166 13f79535-47bb-0310-9956-ffa450edef68
  • Loading branch information
pmouawad committed Oct 17, 2015
1 parent c3b232b commit 714cfd6
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/functions/org/apache/jmeter/functions/JavaScript.java
Original file line number Diff line number Diff line change
Expand Up @@ -58,13 +58,13 @@ private static class LazyHolder {
}

private static final boolean USE_RHINO_ENGINE =
getInstance().getEngineByName(JavaScript.NASHORN_ENGINE_NAME) == null ||
JMeterUtils.getPropDefault(USE_RHINO_ENGINE_PROPERTY, true) ;
JMeterUtils.getPropDefault(USE_RHINO_ENGINE_PROPERTY, true) ||
(getInstance().getEngineByName(JavaScript.NASHORN_ENGINE_NAME) == null);

/**
* @return ScriptEngineManager singleton
*/
public static ScriptEngineManager getInstance() {
private static ScriptEngineManager getInstance() {
return LazyHolder.INSTANCE;
}
private static final List<String> desc = new LinkedList<>();
Expand Down

0 comments on commit 714cfd6

Please sign in to comment.