We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent dc85eae commit ca15fd7Copy full SHA for ca15fd7
src/MabeEnum/Enum.php
@@ -219,7 +219,7 @@ final public static function getByOrdinal($ordinal)
219
$ordinal = (int) $ordinal;
220
$class = get_called_class();
221
$constants = self::detectConstants($class);
222
- $item = array_slice($constants, $ordinal, 1, false);
+ $item = array_slice($constants, $ordinal, 1, true);
223
if (!$item) {
224
throw new InvalidArgumentException(sprintf(
225
'Invalid ordinal number, must between 0 and %s',
0 commit comments