2
0
This commit is contained in:
Cedric Hoelzl 2019-10-21 14:51:53 +02:00
parent a3dcb6a03a
commit 2e13203ece

View File

@ -70,7 +70,7 @@ const cbt = {
function gen_kb(bot, p_en, parr,lang){ function gen_kb(bot, p_en, parr,lang){
let bck_nxt = ""; let bck_nxt = "";
let bck = ""; let bck = "";
let kb = []; let kb = [[]];
let ntmr = tmr; let ntmr = tmr;
for(let k of Object.keys(ntmr)){ for(let k of Object.keys(ntmr)){
if(p_en.indexOf(k.toString()) == -1){ if(p_en.indexOf(k.toString()) == -1){
@ -103,14 +103,14 @@ function gen_kb(bot, p_en, parr,lang){
let str = ctmr.desc[lang]; let str = ctmr.desc[lang];
let c = parr.join("_") + "_" + k.toString(); let c = parr.join("_") + "_" + k.toString();
kb.push(bot.mkcb(str,cbt.sel,c)); kb[0].push(bot.mkcb(str,cbt.sel,c));
} }
} }
if(ntmr.tmr){ if(ntmr.tmr){
for(let i in ntmr.tmr){ for(let i in ntmr.tmr){
let v = ntmr.tmr[i]; let v = ntmr.tmr[i];
let str = ntmr.tmr_str[i]; let str = ntmr.tmr_str[i];
kb.push(bot.mkcb(str,cbt.run,v)) kb[0].push(bot.mkcb(str,cbt.run,v))
} }
} }
} }