mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-01-03 04:29:28 +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();
|
$response = Json\Response::get();
|
||||||
$readonlys = $sel_options = array();
|
$readonlys = $sel_options = array();
|
||||||
|
|
||||||
if (isset($params['mime']))
|
if (!empty($params['mime']))
|
||||||
{
|
{
|
||||||
foreach((array)$params['mime'] as $key => $value)
|
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!");
|
throw new Api\Exception\WrongParameter("Wrong or unset required mode parameter!");
|
||||||
}
|
}
|
||||||
if (isset($params['mime']))
|
if (!empty($params['mime']))
|
||||||
{
|
{
|
||||||
$content['showmime'] = true;
|
$content['showmime'] = true;
|
||||||
$content['mime'] = key($sel_options['mime']);
|
$content['mime'] = key($sel_options['mime']);
|
||||||
|
Loading…
Reference in New Issue
Block a user