Merge pull request #294 from thelounge/astorije/fix-webirc-config

Make sure app does not crash when webirc is not defined in the configuration
This commit is contained in:
Max-P 2016-05-02 01:15:53 -04:00
commit a3c1127755

View file

@ -172,7 +172,7 @@ Client.prototype.connect = function(args) {
return;
}
if (config.webirc !== null && network.host in config.webirc) {
if (config.webirc && network.host in config.webirc) {
args.ip = args.ip || (client.config && client.config.ip) || client.ip;
args.hostname = args.hostname || (client.config && client.config.hostname) || client.hostname || args.ip;