disable proxys before copying files to the trash bin
This commit is contained in:
parent
a2516e549b
commit
8a1223181b
1 changed files with 5 additions and 1 deletions
|
@ -73,8 +73,12 @@ class Trashbin {
|
|||
if ( $trashbinSize === false || $trashbinSize < 0 ) {
|
||||
$trashbinSize = self::calculateSize(new \OC\Files\View('/'. $user.'/files_trashbin'));
|
||||
}
|
||||
|
||||
|
||||
// disable proxy to prevent recursive calls
|
||||
$proxyStatus = \OC_FileProxy::$enabled;
|
||||
\OC_FileProxy::$enabled = false;
|
||||
$sizeOfAddedFiles = self::copy_recursive($file_path, 'files_trashbin/files/'.$filename.'.d'.$timestamp, $view);
|
||||
\OC_FileProxy::$enabled = $proxyStatus;
|
||||
|
||||
if ( $view->file_exists('files_trashbin/files/'.$filename.'.d'.$timestamp) ) {
|
||||
$trashbinSize += $sizeOfAddedFiles;
|
||||
|
|
Loading…
Reference in a new issue