mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-23 00:13:35 +01:00
fix some scrutinizer "bugs"
This commit is contained in:
parent
b47dd39072
commit
23835a2f68
@ -1332,7 +1332,7 @@ class CalDAV extends HTTP_WebDAV_Server
|
||||
($filename = Vfs::basename($matches[1])) != Vfs::basename($path))
|
||||
{
|
||||
$old_path = $path;
|
||||
if (!Vfs::rename($old_path, $path = Vfs::concat(Vfs::dirname($path), $filename)))
|
||||
if (!($dir = Vfs::dirname($path)) || !Vfs::rename($old_path, $path = Vfs::concat($dir, $filename)))
|
||||
{
|
||||
self::xml_error(self::mkprop(self::CALDAV, 'valid-managed-id-parameter', ''));
|
||||
return '403 Forbidden';
|
||||
@ -1499,7 +1499,7 @@ class CalDAV extends HTTP_WebDAV_Server
|
||||
}
|
||||
if ($i >= 100) return null;
|
||||
|
||||
if (!Vfs::file_exists($dir = Vfs::dirname($path)) && !Vfs::mkdir($dir, 0777, STREAM_MKDIR_RECURSIVE))
|
||||
if (!($dir = Vfs::dirname($path)) || !Vfs::file_exists($dir) && !Vfs::mkdir($dir, 0777, STREAM_MKDIR_RECURSIVE))
|
||||
{
|
||||
error_log(__METHOD__."('$app', $id, ...) failed to create entry dir $dir!");
|
||||
return false;
|
||||
|
Loading…
Reference in New Issue
Block a user