fix PHP 8.0 "TypeError: count(): Argument #1 ($value) must be of type Countable|array, string given" when creating a new directory

This commit is contained in:
Ralf Becker 2021-10-07 18:30:59 +02:00
parent 7525a9b186
commit 74433a6a32

View File

@ -684,7 +684,7 @@ class filemanager_ui
*/
static public function action($action,$selected,$dir=null,&$errs=null,&$files=null,&$dirs=null)
{
if (!count($selected))
if (!count((array)$selected))
{
return lang('You need to select some files first!');
}