1
0
Fork 0
mirror of https://github.com/archtechx/enums.git synced 2025-12-12 06:44:04 +00:00

Dropped unnecessary array_pop()

This commit is contained in:
Samuel Levy 2022-03-15 21:52:42 +10:00
parent ad1e07cf39
commit e98222a513

View file

@ -50,6 +50,6 @@ trait From
fn ($c) => $c->name === $case
);
return array_pop($cases) ?? null;
return array_values($cases)[0] ?? null;
}
}