diff --git a/src/MultipartStreamBuilder.php b/src/MultipartStreamBuilder.php index 5a62d75..8156511 100644 --- a/src/MultipartStreamBuilder.php +++ b/src/MultipartStreamBuilder.php @@ -247,10 +247,11 @@ private function basename($path) // For Windows OS add special separator. $separators .= DIRECTORY_SEPARATOR; } - // Remove right-most slashes when $uri points to directory. + + // Remove right-most slashes when $path points to directory. $path = rtrim($path, $separators); - // Returns the trailing part of the $uri starting after one of the directory - // separators. + + // Returns the trailing part of the $path starting after one of the directory separators. $filename = preg_match('@[^'.preg_quote($separators, '@').']+$@', $path, $matches) ? $matches[0] : ''; return $filename;