mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-07 16:44:20 +01:00
fix PHP 8 error: key() Argument #1 must be of type array, null given
This commit is contained in:
parent
3bc0b55d54
commit
e03b1aeb16
@ -409,7 +409,7 @@ class Vfs extends File
|
||||
$response = Json\Response::get();
|
||||
$readonlys = $sel_options = array();
|
||||
|
||||
if (isset($params['mime']))
|
||||
if (!empty($params['mime']))
|
||||
{
|
||||
foreach((array)$params['mime'] as $key => $value)
|
||||
{
|
||||
@ -441,7 +441,7 @@ class Vfs extends File
|
||||
{
|
||||
throw new Api\Exception\WrongParameter("Wrong or unset required mode parameter!");
|
||||
}
|
||||
if (isset($params['mime']))
|
||||
if (!empty($params['mime']))
|
||||
{
|
||||
$content['showmime'] = true;
|
||||
$content['mime'] = key($sel_options['mime']);
|
||||
|
Loading…
Reference in New Issue
Block a user