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

fix file info put on stream

parent d3df80a0
No related branches found
No related tags found
No related merge requests found
......@@ -512,7 +512,19 @@ class Stream {
// Re-enable proxy - our work is done
\OC_FileProxy::$enabled = $proxyStatus;
\OC\Files\Filesystem::putFileInfo( $this->relPath, array( 'encrypted' => 1, 'size' => $this->size, 'unencrypted_size' => $this->unencryptedSize ), '' );
// get file info
$fileInfo = \OC\Files\Filesystem::getFileInfo($this->rawPath);
if(!is_array($fileInfo)) {
$fileInfo = array();
}
// set encryption data
$fileInfo['encrypted'] = 1;
$fileInfo['size'] = $this->size;
$fileInfo['unencrypted_size'] = $this->unencryptedSize;
// set fileinfo
\OC\Files\Filesystem::putFileInfo( $this->rawPath, $fileInfo);
}
return fclose( $this->handle );
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment