From: Evan Prodromou Date: Mon, 22 Jun 2009 22:42:16 +0000 (-0700) Subject: enjitqueuehandler uses functions to check options X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=0b6f3870ad1f77594e8f6dda18465188400aa2e5;p=quix0rs-gnu-social.git enjitqueuehandler uses functions to check options --- diff --git a/scripts/enjitqueuehandler.php b/scripts/enjitqueuehandler.php index c17b4e27f4..2418d2d1c5 100755 --- a/scripts/enjitqueuehandler.php +++ b/scripts/enjitqueuehandler.php @@ -120,15 +120,12 @@ class EnjitQueueHandler extends QueueHandler } -mb_internal_encoding('UTF-8'); - -$id = NULL; - -foreach ($options as $option) { - if ($option[0] == '--id' || $option[0] == '-i') { - $id = $option[1]; - break; - } +if (have_option('-i')) { + $id = get_option_value('-i'); +} else if (have_option('--id')) { + $id = get_option_value('--id'); +} else { + $id = null; } $handler = new EnjitQueueHandler($id);