Skip to content

Commit 68f959b

Browse files
committed
upsome
1 parent 8e41446 commit 68f959b

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

src/Concern/InputOptionsTrait.php

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -123,6 +123,20 @@ public function getBoolOpt(string $name, bool $default = false): bool
123123
return (bool)$this->getOpt($name, $default);
124124
}
125125

126+
/**
127+
* Get (long/short)option value(bool)
128+
* eg: -h --help
129+
*
130+
* @param string[] $names
131+
* @param bool $default
132+
*
133+
* @return bool
134+
*/
135+
public function getSameBoolOpt(array $names, bool $default = false): bool
136+
{
137+
return (bool)$this->getSameOpt($names, $default);
138+
}
139+
126140
/**
127141
* Alias of the getBoolOpt()
128142
*

0 commit comments

Comments
 (0)