Explorar o código

fix: put_tabs() switch tab error

wangweimin %!s(int64=4) %!d(string=hai) anos
pai
achega
af1b1f6130
Modificáronse 1 ficheiros con 1 adicións e 2 borrados
  1. 1 2
      webiojs/src/models/output.ts

+ 1 - 2
webiojs/src/models/output.ts

@@ -254,11 +254,10 @@ function render_tpl(tpl: string, data: { [i: string]: any }) {
         else
             return outputSpecToHtml({type: 'text', content: this, inline: true});
     };
-
     // {{#uniqueid}}name{{/uniqueid}}
     // {{uniqueid}}
+    let names2id: { [name: string]: any } = {};
     data['uniqueid'] = function () {
-        let names2id: { [name: string]: any } = {};
         return function (name: string) {
             if (name) {
                 if (!(name in names2id))