summaryrefslogtreecommitdiff
path: root/it.class
diff options
context:
space:
mode:
Diffstat (limited to 'it.class')
-rw-r--r--it.class4
1 files changed, 2 insertions, 2 deletions
diff --git a/it.class b/it.class
index d28423d..1eafcea 100644
--- a/it.class
+++ b/it.class
@@ -612,7 +612,7 @@ static function getopt($helplines)
if ($longoptname || $shortoptname)
{
- if ($longoptname && $shortoptname)
+ if ($longoptname && ($shortoptname || $shortoptname === "0"))
$alias[$shortoptname] = $longoptname;
$witharg[$longoptname ? $longoptname : $shortoptname] = $longoptarg || $shortoptarg;
@@ -643,7 +643,7 @@ static function getopt($helplines)
else
$result[$optname] = $val ? substr($val, 1) : true;
}
- else if ($letters = it::match('^-(\w+)', $arg))
+ else if (($letters = it::match('^-(\w+)', $arg)) || $letters === "0")
{
foreach (explode("\n", trim(chunk_split($letters, 1, "\n"))) as $letter)
{