mirror of
https://github.com/reality/dbot.git
synced 2024-11-23 20:39:25 +01:00
like
This commit is contained in:
parent
d91c014b53
commit
a45c578037
@ -13,6 +13,21 @@ var words = function(dbot) {
|
||||
});
|
||||
},
|
||||
|
||||
'~like': function(event) {
|
||||
var query = event.params[1];
|
||||
this.wn.word(query, {}, function(err, word) {
|
||||
if(!err && word) {
|
||||
word.related({
|
||||
'limit': 10
|
||||
}, function(err, related) {
|
||||
event.reply('Words related to ' + query + ': ' +
|
||||
related[0].words.join(', ') + '.');
|
||||
});
|
||||
}
|
||||
});
|
||||
|
||||
},
|
||||
|
||||
'~etymology': function(event) {
|
||||
var query = event.params[1];
|
||||
this.wn.etymologies(encodeURIComponent(query), {
|
||||
|
Loading…
Reference in New Issue
Block a user