Skip to content

Commit 53c41be

Browse files
authored
gpcc-copy-to-conditionally-hidden-fields.php: Fixed a potential fatal error.
1 parent cf35e64 commit 53c41be

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

gp-copy-cat/gpcc-copy-to-conditionally-hidden-fields.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@
3232
$source_field = GFAPI::get_field( $form, $target['source'] );
3333
$source_values = $source_field->get_value_submission( array() );
3434
$condition_field = GFAPI::get_field( $form, $target['condition'] );
35-
$condition_value = $condition_field->get_value_submission( $entry );
35+
$condition_value = $condition_field ? $condition_field->get_value_submission( $entry ) : null;
3636

3737
// for multi-input fields, we need to check the index
3838
// to see if the condition is met.

0 commit comments

Comments
 (0)