Code Duplication    Length = 6-6 lines in 3 locations

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

@@ 277-282 (lines=6) @@
274
			$searched_items = false;
275
276
			// @codingStandardsIgnoreLine
277
			if ( isset( $_POST['keyword'] ) ) {
278
				// @codingStandardsIgnoreLine
279
				$keyphrases = $_POST['keyword'];
280
			} else {
281
				$keyphrases = array( 0 );
282
			}
283
284
			if ( ! is_array( $keyphrases ) ) {
285
				$keyphrases = array( $keyphrases );

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

@@ 335-340 (lines=6) @@
332
			$searched_items = false;
333
334
			// @codingStandardsIgnoreLine
335
			if ( isset( $_POST['keyword'] ) ) {
336
				// @codingStandardsIgnoreLine
337
				$keyphrases = $_POST['keyword'];
338
			} else {
339
				$keyphrases = array( 0 );
340
			}
341
342
			if ( ! is_array( $keyphrases ) ) {
343
				$keyphrases = array( $keyphrases );

classes/class-wetu-importer-tours.php 1 location

@@ 378-383 (lines=6) @@
375
				$searched_items = false;
376
377
				// @codingStandardsIgnoreLine
378
				if ( isset( $_POST['keyword'] ) ) {
379
					// @codingStandardsIgnoreLine
380
					$keyphrases = $_POST['keyword'];
381
				} else {
382
					$keyphrases = array( 0 );
383
				}
384
385
				if ( ! is_array( $keyphrases ) ) {
386
					$keyphrases = array( $keyphrases );