]> git.mxchange.org Git - quix0rs-gnu-social.git/blobdiff - scripts/xmppconfirmhandler.php
Fix help text for getvaliddaemons.php
[quix0rs-gnu-social.git] / scripts / xmppconfirmhandler.php
index 883934fd6c9dde66a7a93206b2066eefceabd5a8..d6821ddefae03affd7595396f14489f6a74f8571 100755 (executable)
 
 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 confirmations to Jabber users.
 
-    -r --resource       Jabber Resource ID (default to config)
+    -i --id           Identity (default none)
 
 END_OF_JABBER_HELP;
 
@@ -147,17 +147,17 @@ 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 XmppConfirmHandler($resource);
+$handler = new XmppConfirmHandler($id);
 
 $handler->runOnce();