mirror of
https://github.com/KAMKEEL/CustomNPC-Plus.git
synced 2026-11-13 04:17:36 +00:00
Updated nashorn to use ECMA6
This commit is contained in:
1 parent
745a8a8d93
commit
c5d6179b95
1 file changed
+3
@@ -209,6 +209,9 @@ public class ScriptContainer {
|
||||
public void setEngine(String scriptLanguage) {
|
||||
if(currentScriptLanguage != null && currentScriptLanguage.equals(scriptLanguage))
|
||||
return;
|
||||
if (scriptLanguage.equals("ECMAScript")) {
|
||||
System.setProperty("nashorn.args", "--language=es6");
|
||||
}
|
||||
engine = ScriptController.Instance.getEngineByName(scriptLanguage.toLowerCase());
|
||||
currentScriptLanguage = scriptLanguage;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user