Code Duplication    Length = 4-7 lines in 2 locations

lib/Cake/Routing/Router.php 1 location

@@ 1007-1010 (lines=4) @@
1004
		list($args, $named) = array(Hash::filter($args), Hash::filter($named));
1005
		foreach (self::$_prefixes as $prefix) {
1006
			$prefixed = $prefix . '_';
1007
			if (!empty($url[$prefix]) && strpos($url['action'], $prefixed) === 0) {
1008
				$url['action'] = substr($url['action'], strlen($prefixed) * -1);
1009
				break;
1010
			}
1011
		}
1012
1013
		if (empty($named) && empty($args) && (!isset($url['action']) || $url['action'] === 'index')) {

lib/Cake/View/Helper.php 1 location

@@ 323-329 (lines=7) @@
320
		if (!empty($options['pathPrefix']) && $path[0] !== '/') {
321
			$path = $options['pathPrefix'] . $path;
322
		}
323
		if (
324
			!empty($options['ext']) &&
325
			strpos($path, '?') === false &&
326
			substr($path, -strlen($options['ext'])) !== $options['ext']
327
		) {
328
			$path .= $options['ext'];
329
		}
330
		if (preg_match('|^([a-z0-9]+:)?//|', $path)) {
331
			return $path;
332
		}