浏览代码

Improve handling of JVM arguments on the settings view.

Daniel Scalzi 3 年之前
父节点
当前提交
ee61ea4979
共有 1 个文件被更改,包括 5 次插入1 次删除
  1. 5 1
      app/assets/js/scripts/settings.js

+ 5 - 1
app/assets/js/scripts/settings.js

@@ -180,7 +180,11 @@ function saveSettingsValues(){
                 if(v.type === 'number' || v.type === 'text'){
                 if(v.type === 'number' || v.type === 'text'){
                     // Special Conditions
                     // Special Conditions
                     if(cVal === 'JVMOptions'){
                     if(cVal === 'JVMOptions'){
-                        sFn(v.value.split(' '))
+                        if(!v.value.trim()) {
+                            sFn([])
+                        } else {
+                            sFn(v.value.trim().split(/\s+/))
+                        }
                     } else {
                     } else {
                         sFn(v.value)
                         sFn(v.value)
                     }
                     }