|
@@ 101-103 (lines=3) @@
|
| 98 |
|
|
| 99 |
|
foreach ($paths as $path) { |
| 100 |
|
if (substr($path, $lastOffset, $dirLen) !== $dir) { |
| 101 |
|
if (0 < strlen($common) && DIRECTORY_SEPARATOR === $common[strlen($common) - 1]) { |
| 102 |
|
$common = substr($common, 0, strlen($common) - 1); |
| 103 |
|
} |
| 104 |
|
|
| 105 |
|
return $common; |
| 106 |
|
} |
|
@@ 115-117 (lines=3) @@
|
| 112 |
|
|
| 113 |
|
$common = substr($common, 0, -1); |
| 114 |
|
|
| 115 |
|
if (0 < strlen($common) && DIRECTORY_SEPARATOR === $common[strlen($common) - 1]) { |
| 116 |
|
$common = substr($common, 0, strlen($common) - 1); |
| 117 |
|
} |
| 118 |
|
|
| 119 |
|
return $common; |
| 120 |
|
} |