Skip to content
Snippets Groups Projects
Commit 3e57e76c authored by Robin Appelman's avatar Robin Appelman
Browse files

fix creating the shared folder when the user home folder is not in the root mount

parent 03f66c63
No related branches found
No related tags found
Loading
...@@ -99,12 +99,9 @@ class OC_Share { ...@@ -99,12 +99,9 @@ class OC_Share {
} }
$query->execute(array($uid_owner, $uid, $source, $target, $permissions)); $query->execute(array($uid_owner, $uid, $source, $target, $permissions));
// Emit post_write hook to invoke a file cache rescan // Emit post_write hook to invoke a file cache rescan
$storage = OC_Filesystem::getStorage($sharedFolder); $rootView=new OC_FilesystemView('/');
if (!$storage->is_dir($sharedFolder)) { if (!$rootView->is_dir($sharedFolder)) {
$storage->mkdir($sharedFolder); $rootView->mkdir($sharedFolder);
OCP\Util::emitHook('OC_Filesystem', 'post_write', array('path' => $sharedFolder));
} else {
OCP\Util::emitHook('OC_Filesystem', 'post_write', array('path' => $target));
} }
} }
} }
......
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