mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-28 02:43:22 +01:00
fix PHP Fatal in propatch
This commit is contained in:
parent
2d1ddc1ef7
commit
eca0db5e6f
@ -1787,10 +1787,12 @@ class StreamWrapper extends Api\Db\Pdo implements Vfs\StreamWrapperIface
|
||||
*/
|
||||
static function proppatch($path,array $props)
|
||||
{
|
||||
static $inst = null;
|
||||
if (self::LOG_LEVEL > 1) error_log(__METHOD__."(".array2string($path).','.array2string($props));
|
||||
if (!is_numeric($path))
|
||||
{
|
||||
if (!($stat = $vfs->url_stat($path,0)))
|
||||
if (!isset($inst)) $inst = new self();
|
||||
if (!($stat = $inst->url_stat($path,0)))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
@ -1852,13 +1854,15 @@ class StreamWrapper extends Api\Db\Pdo implements Vfs\StreamWrapperIface
|
||||
*/
|
||||
static function propfind($path_ids,$ns=Vfs::DEFAULT_PROP_NAMESPACE)
|
||||
{
|
||||
static $inst = null;
|
||||
|
||||
$ids = is_array($path_ids) ? $path_ids : array($path_ids);
|
||||
foreach($ids as &$id)
|
||||
{
|
||||
if (!is_numeric($id))
|
||||
{
|
||||
$vfs = new self();
|
||||
if (!($stat = $vfs->url_stat($id,0)))
|
||||
if (!isset($inst)) $inst = new self();
|
||||
if (!($stat = $inst->url_stat($id,0)))
|
||||
{
|
||||
if (self::LOG_LEVEL) error_log(__METHOD__."(".array2string($path_ids).",$ns) path '$id' not found!");
|
||||
return false;
|
||||
|
Loading…
Reference in New Issue
Block a user