Skip to content
Snippets Groups Projects
Commit 51710566 authored by Florin Peter's avatar Florin Peter
Browse files

fix for public link share

parent 81ae4cb5
No related branches found
No related tags found
No related merge requests found
...@@ -1096,7 +1096,7 @@ class Util { ...@@ -1096,7 +1096,7 @@ class Util {
// handle public access // handle public access
if($fileOwnerUid === false && $this->isPublic) { if($fileOwnerUid === false && $this->isPublic) {
$filename = $this->fileIdToPath( $GLOBALS['fileSource'] ); $filename = $path;
$fileOwnerUid = $GLOBALS['fileOwner']; $fileOwnerUid = $GLOBALS['fileOwner'];
return array ( $fileOwnerUid, $filename ); return array ( $fileOwnerUid, $filename );
......
...@@ -428,7 +428,6 @@ class Test_Encryption_Share extends \PHPUnit_Framework_TestCase ...@@ -428,7 +428,6 @@ class Test_Encryption_Share extends \PHPUnit_Framework_TestCase
// some hacking to simulate public link // some hacking to simulate public link
$GLOBALS['app'] = 'files_sharing'; $GLOBALS['app'] = 'files_sharing';
$GLOBALS['fileOwner'] = 'admin'; $GLOBALS['fileOwner'] = 'admin';
$GLOBALS['fileSource'] = $fileInfo['fileid'];
\OC_User::setUserId(''); \OC_User::setUserId('');
// get file contents // get file contents
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment