Resolve path for reshares. Closes #66

This commit is contained in:
Victor Dubiniuk 2013-10-17 00:04:25 +03:00
parent 9bfc7e5058
commit 2ee654c1ea

View File

@ -164,7 +164,11 @@ class File {
$origins = array(); $origins = array();
if (is_array($shares)){ if (is_array($shares)){
foreach ($shares as $share){ foreach ($shares as $share){
$origins[] = \OCP\Share::resolveReShare($share); $origin = \OCP\Share::resolveReShare($share);
if (!isset($origin['path']) && isset($origin['file_target'])){
$origin['path'] = 'files/' . $origin['file_target'];
}
$origins[] = $origin;
} }
} }
return $origins; return $origins;