2
0

init wiki

This commit is contained in:
Cedric Hoelzl 2019-10-15 21:56:47 +02:00
parent c44e376d9c
commit bbe47ce309
2 changed files with 1 additions and 18 deletions

View File

@ -36,7 +36,7 @@ module.exports = function(){
let t = r.speech!=''?r.speech:"Other" let t = r.speech!=''?r.speech:"Other"
txt+= `*${t}:*\n`; txt+= `*${t}:*\n`;
for(let l of r.lines){ for(let l of r.lines){
txt+= ` - _${l.define}_\n\n`; txt+= `${l.define}\n\n`;
} }
txt += `\n`; txt += `\n`;
} }

View File

@ -145,20 +145,3 @@ var wiki = function () {
module.exports = wiki; module.exports = wiki;
return wiki('gay').then(res=>{
let txt = `*Definitions of ${res.word}:*\n\n`;
for(let r of res.definitions){
console.log(r)
let t = r.speech!=''?r.speech:"Other"
txt+= `*${r.speech}:*\n`;
for(let l of r.lines){
txt+= ` - _${l.define}_\n\n`;
}
txt += `\n`;
}
console.log(txt);
}).catch(err=>{
})