Code Duplication    Length = 4-4 lines in 2 locations

Rule/Url.php 2 locations

@@ 95-98 (lines=4) @@
92
93
		// The best we can do for the rest is make sure that the strings are valid UTF-8
94
		// and the port is an integer.
95
		if (array_key_exists('host', $urlParts) && !StringHelper::valid((string) $urlParts['host']))
96
		{
97
			return false;
98
		}
99
100
		if (array_key_exists('port', $urlParts) && !is_int((int) $urlParts['port']))
101
		{
@@ 105-108 (lines=4) @@
102
			return false;
103
		}
104
105
		if (array_key_exists('path', $urlParts) && !StringHelper::valid((string) $urlParts['path']))
106
		{
107
			return false;
108
		}
109
110
		return true;
111
	}