Skip to content

Commit

Permalink
array_key_exists only if is_array
Browse files Browse the repository at this point in the history
  • Loading branch information
jerome2710 committed Nov 14, 2024
1 parent 8b41885 commit e2b5b25
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Kunstmaan/AdminListBundle/Service/ExportService.php
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ protected function streamOutput(ExportableInterface $adminList, $format)

$iterator = $adminList->getIterator();
foreach ($iterator as $item) {
if (\array_key_exists(0, $item)) {
if (\is_array($item) && \array_key_exists(0, $item)) {
$itemObject = $item[0];
} else {
$itemObject = $item;
Expand Down

0 comments on commit e2b5b25

Please sign in to comment.