Code Duplication    Length = 12-12 lines in 2 locations

core/Datastore/Key_Value_Datastore.php 1 location

@@ 175-186 (lines=12) @@
172
			);
173
			$this->save_key_value_pair( $storage_key, '' );
174
		}
175
		foreach ( $value_set as $value_group_index => $values ) {
176
			foreach ( $values as $value_key => $value ) {
177
				$storage_key = $this->key_toolset->get_storage_key(
178
					$field->is_simple_root_field(),
179
					$this->get_full_hierarchy_for_field( $field ),
180
					$this->get_full_hierarchy_index_for_field( $field ),
181
					$value_group_index,
182
					$value_key
183
				);
184
				$this->save_key_value_pair( $storage_key, $value );
185
			}
186
		}
187
	}
188
}
189

core/Datastore/Theme_Options_Datastore.php 1 location

@@ 91-102 (lines=12) @@
88
			);
89
			$this->save_key_value_pair_with_autoload( $storage_key, '', $autoload );
90
		}
91
		foreach ( $value_set as $value_group_index => $values ) {
92
			foreach ( $values as $value_key => $value ) {
93
				$storage_key = $this->key_toolset->get_storage_key(
94
					$field->is_simple_root_field(),
95
					$this->get_full_hierarchy_for_field( $field ),
96
					$this->get_full_hierarchy_index_for_field( $field ),
97
					$value_group_index,
98
					$value_key
99
				);
100
				$this->save_key_value_pair_with_autoload( $storage_key, $value, $autoload );
101
			}
102
		}
103
	}
104
105
	/**