浏览代码

HUE-4253 [editor] Prompt for variables just once per variable name

Enrico Berti 9 年之前
父节点
当前提交
203e2a1183
共有 1 个文件被更改,包括 3 次插入1 次删除
  1. 3 1
      desktop/libs/notebook/src/notebook/static/notebook/js/notebook.ko.js

+ 3 - 1
desktop/libs/notebook/src/notebook/static/notebook/js/notebook.ko.js

@@ -379,7 +379,9 @@
 
       var match, matches = [];
       while (match = re.exec(self.statement_raw())) {
-        matches.push(match[1]);
+        if (matches.indexOf(match[1]) == -1) {
+          matches.push(match[1]);
+        }
       }
       return matches;
     });