From 6b4ad05b89506a0ceb3ae3d47e9c4c1b91cae67f Mon Sep 17 00:00:00 2001 From: "Christoph M. Becker" Date: Sun, 28 Oct 2018 15:24:40 +0100 Subject: [PATCH] Fix #370: Filebrowser can mark closed folder as opened When doing string comparison of folder names, we have to make sure the folders are terminated with a slash. --- plugins/filebrowser/classes/View.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/filebrowser/classes/View.php b/plugins/filebrowser/classes/View.php index 130f1505..b75457e2 100644 --- a/plugins/filebrowser/classes/View.php +++ b/plugins/filebrowser/classes/View.php @@ -176,7 +176,7 @@ public function folderLink($folder, array $folders) global $sn; $class = 'folder'; - if (substr($this->currentDirectory, 0, strlen($folder)) == $folder) { + if (substr($this->currentDirectory, 0, strlen("$folder/")) == "$folder/") { $class = 'openFolder'; } $temp = explode('/', $folder);