Skip to content

Commit

Permalink
Temporarily map without key for compatibility during refactor
Browse files Browse the repository at this point in the history
  • Loading branch information
caendesilva committed Jan 8, 2023
1 parent c94a528 commit 954a6cf
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -216,6 +216,11 @@ protected function getPublicationsSortedByPaginationField(): Collection

protected function parseFieldData(array $fields): Collection
{
return Collection::make($fields)->map(function (array $data): PublicationFieldDefinition {
return new PublicationFieldDefinition(...$data);
});

// FIXME
return Collection::make($fields)->mapWithKeys(function (array $data): array {
return [$data['name'] => new PublicationFieldDefinition(...$data)];
});
Expand Down

0 comments on commit 954a6cf

Please sign in to comment.