@@ 1011-1013 (lines=3) @@ | ||
1008 | // for several files - create new directory |
|
1009 | // create unique name for directory |
|
1010 | $name = basename($path); |
|
1011 | if (preg_match('/\.((tar\.(gz|bz|bz2|z|lzo))|cpio\.gz|ps\.gz|xcf\.(gz|bz2)|[a-z0-9]{1,4})$/i', $name, $m)) { |
|
1012 | $name = substr($name, 0, strlen($name) - strlen($m[0])); |
|
1013 | } |
|
1014 | ||
1015 | $test = dirname($path) . DIRECTORY_SEPARATOR . $name; |
|
1016 | if ($this->stat($test)) { |
@@ 714-716 (lines=3) @@ | ||
711 | // for several files - create new directory |
|
712 | // create unique name for directory |
|
713 | $name = basename($path); |
|
714 | if (preg_match('/\.((tar\.(gz|bz|bz2|z|lzo))|cpio\.gz|ps\.gz|xcf\.(gz|bz2)|[a-z0-9]{1,4})$/i', $name, $m)) { |
|
715 | $name = substr($name, 0, strlen($name)-strlen($m[0])); |
|
716 | } |
|
717 | $test = dirname($path).DIRECTORY_SEPARATOR.$name; |
|
718 | if (file_exists($test) || is_link($test)) { |
|
719 | $name = $this->uniqueName(dirname($path), $name, '-', false); |