Code Duplication    Length = 5-10 lines in 2 locations

classes/Pods.php 2 locations

@@ 2985-2989 (lines=5) @@
2982
			if ( empty( $value ) ) {
2983
				return $id;
2984
			}
2985
		} elseif ( in_array( $this->fields[ $field ]['type'], PodsForm::number_field_types(), true ) ) {
2986
			// Number fields.
2987
			$current_value = (float) $pod->raw( $field );
2988
2989
			$value = ( $current_value + (float) $value );
2990
		} elseif ( in_array( $this->fields[ $field ]['type'], PodsForm::date_field_types(), true ) ) {
2991
			// Date fields.
2992
			$current_value = $pod->raw( $field );
@@ 3117-3126 (lines=10) @@
3114
					$value = array();
3115
				}
3116
			}//end if
3117
		} elseif ( in_array( $this->fields[ $field ]['type'], PodsForm::number_field_types(), true ) ) {
3118
			// Number fields.
3119
			// Date fields don't support empty for removing.
3120
			if ( empty( $value ) ) {
3121
				return $id;
3122
			}
3123
3124
			$current_value = (float) $pod->raw( $field );
3125
3126
			$value = ( $current_value - (float) $value );
3127
		} elseif ( in_array( $this->fields[ $field ]['type'], PodsForm::date_field_types(), true ) ) {
3128
			// Date fields.
3129
			// Date fields don't support empty for removing.