Skip to content

Commit d0c7385

Browse files
committed
Fix getColumnsFromAbraFlexi to handle string conditions
Convert string conditions to array with 'filter' key to prevent TypeError when accessing array offset on string type. This fixes issues when conditions are passed as string instead of array.
1 parent 3d3b37d commit d0c7385

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/AbraFlexi/RO.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1881,6 +1881,11 @@ public function getColumnsFromAbraFlexi(
18811881
break;
18821882
}
18831883

1884+
// Ensure conditions is an array
1885+
if (\is_string($conditions)) {
1886+
$conditions = ['filter' => $conditions];
1887+
}
1888+
18841889
$conditions['detail'] = $detail;
18851890
$flexiData = $this->getFlexiData('', $conditions);
18861891

0 commit comments

Comments
 (0)