Skip to content
Snippets Groups Projects
Commit cc433d47 authored by Björn Schießle's avatar Björn Schießle
Browse files

touch() needs to be performed relative to user/files otherwise ownCloud...

touch() needs to be performed relative to user/files otherwise ownCloud doesn't execute the hooks which means that etags aren't updated properly
parent 2e81efc3
No related branches found
No related tags found
No related merge requests found
......@@ -266,7 +266,10 @@ class Trashbin {
// handle the restore result
if( $restoreResult ) {
$view->touch($target.$ext, $mtime);
$fakeRoot = $view->getRoot();
$view->chroot('/'.$user.'/files');
$view->touch('/'.$location.'/'.$filename.$ext, $mtime);
$view->chroot($fakeRoot);
\OCP\Util::emitHook('\OCA\Files_Trashbin\Trashbin', 'post_restore',
array('filePath' => \OC\Files\Filesystem::normalizePath('/'.$location.'/'.$filename.$ext),
'trashPath' => \OC\Files\Filesystem::normalizePath($file)));
......
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