Add check if file is found in file cache

remotes/origin/stable45
Michael Gapczynski 13 years ago
parent ac395dced1
commit bdcfa4bb63
  1. 4
      lib/public/share.php

@ -562,6 +562,10 @@ class Share {
} else if (is_array($source)) {
$itemSource = $source['item'];
$fileSource = \OC_FileCache::getId($source['file']);
if ($fileSource == -1) {
\OC_Log::write('OCP\Share', 'Sharing '.$item.' failed, because the file could not be found in the file cache', \OC_Log::ERROR);
return false;
}
} else {
$itemSource = $source;
$fileSource = null;

Loading…
Cancel
Save