From ce393af7a649189d9ae6f78c4f73e870e4110b34 Mon Sep 17 00:00:00 2001 From: Boy132 Date: Wed, 17 Sep 2025 12:35:20 +0200 Subject: [PATCH] Fix `join_paths` for absolute linux paths (#1715) --- app/helpers.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/helpers.php b/app/helpers.php index e447e1fd6..241a116ac 100644 --- a/app/helpers.php +++ b/app/helpers.php @@ -52,7 +52,7 @@ if (!function_exists('convert_bytes_to_readable')) { if (!function_exists('join_paths')) { function join_paths(string $base, string ...$paths): string { - $base = trim($base, '/'); + $base = rtrim($base, '/'); $paths = array_map(fn (string $path) => trim($path, '/'), $paths); $paths = array_filter($paths, fn (string $path) => strlen($path) > 0);