]> git.mxchange.org Git - quix0rs-gnu-social.git/blobdiff - scripts/jabberqueuehandler.php
Merge branch '0.9.x' of git://gitorious.org/statusnet/mainline into 0.9.x
[quix0rs-gnu-social.git] / scripts / jabberqueuehandler.php
index a449932364d70bcf4585cf4a613911cfbc0d749e..8f3a56944d550d2d2e89eaf2e892e64401e46bec 100755 (executable)
@@ -1,8 +1,8 @@
 #!/usr/bin/env php
 <?php
 /*
- * Laconica - a distributed open-source microblogging tool
- * Copyright (C) 2008, 2009, Control Yourself, Inc.
+ * StatusNet - the distributed open-source microblogging tool
+ * Copyright (C) 2008, 2009, StatusNet, Inc.
  *
  * This program is free software: you can redistribute it and/or modify
  * it under the terms of the GNU Affero General Public License as published by
 
 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();