Skip to content

Commit

Permalink
Fix the name field display/email order (#2558)
Browse files Browse the repository at this point in the history
* Fix the name field display/email order

* Fix key
  • Loading branch information
EvanHerman committed Aug 10, 2023
1 parent bb9d0bd commit 2026dd1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion includes/class-coblocks-form.php
Original file line number Diff line number Diff line change
Expand Up @@ -903,7 +903,7 @@ public function process_form_submission( $atts ) {

if ( is_array( $data['value'] ) ) {

$data['value'] = implode( ', ', $data['value'] );
$data['value'] = ( array_key_exists( 'first-name', $data['value'] ) && array_key_exists( 'last-name', $data['value'] ) ) ? $data['value']['last-name'] . ', ' . $data['value']['first-name'] : implode( ', ', $data['value'] );

}

Expand Down

0 comments on commit 2026dd1

Please sign in to comment.