Code Duplication    Length = 16-16 lines in 2 locations

app/classes/comment.php 1 location

@@ 322-337 (lines=16) @@
319
	 *
320
	 * @return boolean
321
	 */
322
	protected function update_child_levels() {
323
324
		if ( is_array( $this->children ) ) {
325
326
			foreach ( $this->children as $child ) {
327
				$child->level = $this->level + 1;
328
				$child->update_child_levels();
329
			}
330
331
			return true;
332
333
		}
334
335
		return false;
336
337
	}
338
}
339

app/classes/menu_item.php 1 location

@@ 159-174 (lines=16) @@
156
	 *
157
	 * @return boolean
158
	 */
159
	protected function update_child_levels() {
160
161
		if ( is_array( $this->children ) ) {
162
163
			foreach ( $this->children as $child ) {
164
				$child->level = $this->level + 1;
165
				$child->update_child_levels();
166
			}
167
168
			return true;
169
170
		}
171
172
		return false;
173
174
	}
175
}
176