summaryrefslogtreecommitdiff
path: root/scripts/jabberqueuehandler.php
diff options
context:
space:
mode:
authorEvan Prodromou <evan@controlyourself.ca>2009-06-24 19:31:12 -0700
committerEvan Prodromou <evan@controlyourself.ca>2009-06-24 19:31:12 -0700
commitbecfd6b3b5da57298137c3349efbd49fe347ccfd (patch)
treefb8e162669840a039135e54c6388fd35d45e14b4 /scripts/jabberqueuehandler.php
parenta6c56d17e04bf3bd164290c352137dc7345c4f01 (diff)
all daemons take an id parameter
Diffstat (limited to 'scripts/jabberqueuehandler.php')
-rwxr-xr-xscripts/jabberqueuehandler.php20
1 files changed, 10 insertions, 10 deletions
diff --git a/scripts/jabberqueuehandler.php b/scripts/jabberqueuehandler.php
index a44993236..5b581629d 100755
--- a/scripts/jabberqueuehandler.php
+++ b/scripts/jabberqueuehandler.php
@@ -20,13 +20,13 @@
define('INSTALLDIR', realpath(dirname(__FILE__) . '/..'));
-$shortoptions = 'r::';
-$longoptions = array('resource::');
+$shortoptions = 'i::';
+$longoptions = array('id::');
$helptext = <<<END_OF_JABBER_HELP
Daemon script for pushing new notices to Jabber users.
- -r --resource Jabber Resource ID (default to config)
+ -i --id Identity (default none)
END_OF_JABBER_HELP;
@@ -63,16 +63,16 @@ if (common_config('xmpp','enabled')==false) {
exit();
}
-if (have_option('r')) {
- $resource = get_option_value('r');
-} else if (have_option('--resource')) {
- $resource = get_option_value('--resource');
+if (have_option('i')) {
+ $id = get_option_value('i');
+} else if (have_option('--id')) {
+ $id = get_option_value('--id');
} else if (count($args) > 0) {
- $resource = $args[0];
+ $id = $args[0];
} else {
- $resource = null;
+ $id = null;
}
-$handler = new JabberQueueHandler($resource);
+$handler = new JabberQueueHandler($id);
$handler->runOnce();