Mercurial > psgxs
changeset 45:8b20f2efb939
Add an option to choose the host and port of the connection.
author | Emmanuel Gil Peyrot <linkmauve@linkmauve.fr> |
---|---|
date | Tue, 08 Mar 2011 00:25:17 +0100 |
parents | 3e0ca96d2dce |
children | 3126f8d6a5e3 |
files | configuration.js psgxs.js |
diffstat | 2 files changed, 3 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- 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';
--- 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);