Enable link fetcher
This commit is contained in:
parent
356851c3f2
commit
82e192cd2c
@ -9,7 +9,7 @@ process.setMaxListeners(0);
|
||||
|
||||
module.exports = function(irc, network) {
|
||||
var client = this;
|
||||
irc.on("message", function(data) {
|
||||
irc.on("privmsg", function(data) {
|
||||
var config = Helper.getConfig();
|
||||
if (!config.prefetch) {
|
||||
return;
|
||||
@ -27,8 +27,7 @@ module.exports = function(irc, network) {
|
||||
return;
|
||||
}
|
||||
|
||||
var self = data.to.toLowerCase() === irc.user.nick.toLowerCase();
|
||||
var chan = _.find(network.channels, {name: self ? data.from : data.to});
|
||||
var chan = _.find(network.channels, {name: data.target});
|
||||
if (typeof chan === "undefined") {
|
||||
return;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user