Code Duplication    Length = 5-5 lines in 2 locations

classes/class-lsx-wetu-importer-accommodation.php 1 location

@@ 306-310 (lines=5) @@
303
304
				$accommodation = array();
305
				$current_accommodation = $this->find_current_accommodation();
306
				if ( ! empty( $current_accommodation ) ) {
307
					foreach ( $current_accommodation as $cs_key => $ccs_id ) {
308
						$accommodation[] = $this->prepare_row_attributes( $cs_key, $ccs_id->post_id );
309
					}
310
				}
311
312
				// Run through each accommodation and use it.
313
				if ( ! empty( $accommodation ) ) {

classes/class-lsx-wetu-importer-destination.php 1 location

@@ 363-367 (lines=5) @@
360
361
				$accommodation = array();
362
				$current_accommodation = $this->find_current_accommodation( 'destination' );
363
				if ( ! empty( $current_accommodation ) ) {
364
					foreach ( $current_accommodation as $cs_key => $ccs_id ) {
365
						$accommodation[] = $this->prepare_row_attributes( $cs_key, $ccs_id->post_id );
366
					}
367
				}
368
369
				// Run through each accommodation and use it.
370
				if ( ! empty( $accommodation ) ) {