also trim base

This commit is contained in:
Boy132 2025-09-05 14:08:15 +02:00
parent b6e991053d
commit 5b362208e1

View File

@ -52,6 +52,8 @@ if (!function_exists('convert_bytes_to_readable')) {
if (!function_exists('join_paths')) {
function join_paths(string $base, string ...$paths): string
{
$base = trim($base, '/');
$paths = array_map(fn (string $path) => trim($path, '/'), $paths);
$paths = array_filter($paths, fn (string $path) => strlen($path) > 0);