# HG changeset patch # User Emmanuel Gil Peyrot # Date 1299540317 -3600 # Node ID 8b20f2efb93947c364cb4a5ecf135da4189c3544 # Parent 3e0ca96d2dcef0aea7e2d0863413127f96da508d Add an option to choose the host and port of the connection. diff --git a/configuration.js b/configuration.js --- a/configuration.js +++ b/configuration.js @@ -23,6 +23,8 @@ var config = exports; config.jid = 'pubsub.example.org'; config.password = 'hellohello'; +config.host = 'localhost'; +config.port = 5347; config.superOwner = ['you@example.com']; config.version = '0.1'; config.os = 'GNU/Linux'; diff --git a/psgxs.js b/psgxs.js --- a/psgxs.js +++ b/psgxs.js @@ -31,7 +31,7 @@ var fdsq = require('./fdsq'); var toBareJID = fdsq.toBareJID; var config = require('./configuration'); var forms = require('./forms'); -var conn = new xmpp.Connection(); +var conn = new xmpp.Connection(config.host, config.port); var notifs = require('./notifs'); notifs.setConnection(conn);