mirror of
https://github.com/reality/dbot.git
synced 2024-11-27 06:19:24 +01:00
set last link in channel when ~yt command is used
This commit is contained in:
parent
bb28cebde1
commit
597171c37d
@ -93,6 +93,7 @@ var youtube = function(dbot) {
|
||||
}, function(error, response, body) {
|
||||
if(_.isObject(body) && _.has(body, 'items') && body.items.length > 0) {
|
||||
event.reply(this.internalAPI.formatLink(body.items[0]));
|
||||
dbot.modules.link.links[event.channel.name] = 'https://youtu.be/' + body.items[0].id;
|
||||
}
|
||||
}.bind(this));
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user