Skip to content

Commit

Permalink
Fix Combiner referencing function on 'null' value.
Browse files Browse the repository at this point in the history
  • Loading branch information
doekenorg committed Jan 24, 2025
1 parent 7fdb2c0 commit f3ecbd9
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -259,6 +259,7 @@ You can hide a row by adding a hook. Checkout this example:
= develop =

* Enhancement: Nested forms can now also export entry meta values.
* Fixed: Nested form values could cause an exception.

= 2.3.7 on January 17, 2025 =

Expand Down
3 changes: 2 additions & 1 deletion src/Transformer/Combiner.php
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,8 @@ public function parseEntry( array $fields, array $entry ): void {
return $output;
}, '' );

$gf_field = array_filter( $values ) ? reset( $values )->getField() : new GF_Field();
$non_empty_values = array_filter( $values );
$gf_field = $non_empty_values ? reset( $non_empty_values )->getField() : new GF_Field();

$combined_row[ $column ] = new StringValue( $combined, $gf_field );
}
Expand Down

0 comments on commit f3ecbd9

Please sign in to comment.