FIX Use DataColumns content when available in CSV export

Fix #9248 broke #9173 by accidentally checking for a string key in a
numerically indexed array. Change the check to search the array instead
(fixes #10308)
This commit is contained in:
Steve Piner 2022-05-11 08:47:14 +12:00
parent d9d65c4fb0
commit e91b7be056
1 changed files with 1 additions and 1 deletions

View File

@ -234,7 +234,7 @@ class GridFieldExportButton implements GridField_HTMLProvider, GridField_ActionP
}
$value = $columnHeader($relObj);
} elseif ($gridFieldColumnsComponent && array_key_exists($columnSource, $columnsHandled)) {
} elseif ($gridFieldColumnsComponent && in_array($columnSource, $columnsHandled)) {
$value = strip_tags(
$gridFieldColumnsComponent->getColumnContent($gridField, $item, $columnSource)
);