Code Duplication    Length = 8-10 lines in 2 locations

core/Container/Term_Meta_Container.php 1 location

@@ 67-76 (lines=10) @@
64
	 *
65
	 * @param int $term_id ID of the term against which save() is ran
66
	 */
67
	public function save( $term_id = null ) {
68
		$this->set_term_id( $term_id );
69
70
		foreach ( $this->fields as $field ) {
71
			$field->set_value_from_input( stripslashes_deep( $_POST ) );
72
			$field->save();
73
		}
74
75
		do_action( 'carbon_fields_term_meta_container_saved', $term_id, $this );
76
	}
77
78
	/**
79
	 * Get environment array for page request (in admin)

core/Container/Nav_Menu_Item_Container.php 1 location

@@ 82-89 (lines=8) @@
79
	 * Perform save operation after successful is_valid_save() check.
80
	 * The call is propagated to all fields in the container.
81
	 */
82
	public function save( $data = null ) {
83
		foreach ( $this->fields as $field ) {
84
			$field->set_value_from_input( stripslashes_deep( $_POST ) );
85
			$field->save();
86
		}
87
88
		do_action( 'carbon_fields_nav_menu_item_container_saved', $this );
89
	}
90
91
	/**
92
	 * {@inheritDoc}