Code Duplication    Length = 4-4 lines in 2 locations

packages/sync/src/class-functions.php 2 locations

@@ 402-405 (lines=4) @@
399
			return $url;
400
		}
401
402
		if ( "www.{$option_url[ 'host' ]}" === $url['host'] ) {
403
			// remove www if not present in option URL.
404
			$url['host'] = $option_url['host'];
405
		}
406
		if ( "www.{$url[ 'host' ]}" === $option_url['host'] ) {
407
			// add www if present in option URL.
408
			$url['host'] = $option_url['host'];
@@ 406-409 (lines=4) @@
403
			// remove www if not present in option URL.
404
			$url['host'] = $option_url['host'];
405
		}
406
		if ( "www.{$url[ 'host' ]}" === $option_url['host'] ) {
407
			// add www if present in option URL.
408
			$url['host'] = $option_url['host'];
409
		}
410
411
		$normalized_url = "{$url['scheme']}://{$url['host']}";
412
		if ( isset( $url['path'] ) ) {