PluginProbe
Formidable Forms – WordPress Form Builder for Contact Forms, Calculators, Quizzes & More / trunk
Formidable Forms – WordPress Form Builder for Contact Forms, Calculators, Quizzes & More vtrunk
6.35 6.34 6.33.1 6.33 6.32.1 6.32 6.31 6.25 6.25.1 6.26 6.26.1 6.27 6.28 6.29 6.3 6.3.1 6.3.2 6.30 6.4 6.4.1 6.4.2 6.5 6.5.1 6.5.2 6.5.3 All 141 releases
← All changes | classes/helpers/FrmCSVExportHelper.php +11 -9 6.28 → trunk View file →
@@ -521,12 +521,12 @@
521 521 foreach ( $entries as $entry ) {
522 522 self::$entry = $entry;
523 523 unset( $entry );
524 524
525 - if ( self::$entry->form_id !== self::$form_id ) {
525 + if ( self::$entry->form_id === self::$form_id ) {
526 + self::prepare_csv_row();
527 + } else {
526 528 self::add_repeat_field_values_to_csv( $entries );
527 - } else {
528 - self::prepare_csv_row();
529 529 }
530 530 }
531 531 }
532 532
@@ -617,17 +617,19 @@
617 617 return $metas;
618 618 }
619 619
620 620 foreach ( self::$fields_by_repeater_id[ $repeater_id ] as $repeater_child ) {
621 - if ( ! isset( $metas[ $repeater_child->id ] ) ) {
622 - $metas[ $repeater_child->id ] = '';
621 + if ( isset( $metas[ $repeater_child->id ] ) ) {
622 + continue;
623 + }
623 624
624 - if ( ! isset( $entries[ self::$entry->parent_item_id ]->metas[ $repeater_child->id ] ) || ! is_array( $entries[ self::$entry->parent_item_id ]->metas[ $repeater_child->id ] ) ) { // phpcs:ignore SlevomatCodingStandard.Files.LineLength.LineTooLong
625 - $entries[ self::$entry->parent_item_id ]->metas[ $repeater_child->id ] = array();
626 - }
625 + $metas[ $repeater_child->id ] = '';
627 626
628 - $entries[ self::$entry->parent_item_id ]->metas[ $repeater_child->id ][] = '';
627 + if ( ! isset( $entries[ self::$entry->parent_item_id ]->metas[ $repeater_child->id ] ) || ! is_array( $entries[ self::$entry->parent_item_id ]->metas[ $repeater_child->id ] ) ) { // phpcs:ignore SlevomatCodingStandard.Files.LineLength.LineTooLong
628 + $entries[ self::$entry->parent_item_id ]->metas[ $repeater_child->id ] = array();
629 629 }
630 +
631 + $entries[ self::$entry->parent_item_id ]->metas[ $repeater_child->id ][] = '';
630 632 }
631 633
632 634 return $metas;
633 635 }