Skip to content

Commit

Permalink
Merge branch 'validate-on-whereuuid-scope'
Browse files Browse the repository at this point in the history
  • Loading branch information
michaeldyrynda committed Mar 7, 2022
2 parents 160d9ea + eb09bc4 commit ce78fce
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/GeneratesUuid.php
Original file line number Diff line number Diff line change
Expand Up @@ -165,9 +165,13 @@ protected function bytesFromUuid($uuid): array
*/
protected function normaliseUuids($uuid): array
{
$uuid = array_map(fn ($uuid) => Str::lower($uuid), Arr::wrap($uuid));
$uuid = array_map(function ($uuid) {
return Str::lower($uuid);
}, Arr::wrap($uuid));

$uuid = array_filter($uuid, fn ($uuid) => Uuid::isValid($uuid));
$uuid = array_filter($uuid, function ($uuid) {
return Uuid::isValid($uuid);
});

return $uuid;
}
Expand Down

0 comments on commit ce78fce

Please sign in to comment.