mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-07 16:44:07 +01:00
Make sure share cleanup job doesn't remove shares just because of access rights
This commit is contained in:
parent
2e753d942a
commit
c937f50193
@ -126,6 +126,10 @@ class Sharing extends \EGroupware\Api\Sharing
|
||||
protected static function check_path($share)
|
||||
{
|
||||
list($app, $id) = explode('::', $share['share_path']);
|
||||
if(!\EGroupware\Api\Link::$app_register[$app])
|
||||
{
|
||||
\EGroupware\Api\Link::init_static();
|
||||
}
|
||||
return (boolean) \EGroupware\Api\Link::title($app, $id);
|
||||
}
|
||||
|
||||
|
@ -825,7 +825,7 @@ class Sharing
|
||||
if (!isset(self::$db)) self::$db = $GLOBALS['egw']->db;
|
||||
|
||||
foreach(self::$db->select(self::TABLE, array(
|
||||
'share_id','share_path'
|
||||
'share_id','share_path', 'share_writable'
|
||||
), array(), __LINE__, __FILE__, false) as $share)
|
||||
{
|
||||
$class = self::get_share_class($share);
|
||||
|
@ -364,7 +364,10 @@ class Sharing extends \EGroupware\Api\Sharing
|
||||
{
|
||||
$share['share_path'] = Api\Vfs::parse_url($share['share_path'], PHP_URL_PATH);
|
||||
}
|
||||
return Vfs::file_exists($share['share_path']);
|
||||
Vfs::$is_root = true;
|
||||
$exists = Vfs::file_exists($share['share_path']);
|
||||
Vfs::$is_root = false;
|
||||
return $exists;
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user