Code Duplication    Length = 6-6 lines in 2 locations

classes/PodsUI.php 1 location

@@ 1633-1638 (lines=6) @@
1630
1631
			$fields[ $field[ 'name' ] ] = $field;
1632
1633
            if ( empty( $this->id ) && null !== $default_value ) {
1634
                $this->pod->row_override[ $field[ 'name' ] ] = $default_value;
1635
			}
1636
			elseif ( !empty( $this->id ) && null !== $value ) {
1637
                $this->pod->row[ $field[ 'name' ] ] = $value;
1638
			}
1639
        }
1640
1641
        unset( $form_fields ); // Cleanup

classes/Pods.php 1 location

@@ 3448-3453 (lines=6) @@
3445
3446
			$fields[ $field[ 'name' ] ] = $field;
3447
3448
			if ( empty( $this->id ) && null !== $default_value ) {
3449
				$this->row_override[ $field[ 'name' ] ] = $default_value;
3450
			}
3451
			elseif ( !empty( $this->id ) && null !== $value ) {
3452
				$this->row[ $field[ 'name' ] ] = $value;
3453
			}
3454
		}
3455
3456
		unset( $form_fields ); // Cleanup