Merge pull request #22273 from owncloud/versions-fixpathasrecipient

Fix versions path as share recipient when different than owner path
This commit is contained in:
Thomas Müller 2016-02-10 17:25:14 +01:00
commit 10613f7265
2 changed files with 7 additions and 1 deletions

View File

@ -41,6 +41,11 @@ if( $versions ) {
$versions = array_slice($versions, $start, $count);
// remove owner path from request to not disclose it to the recipient
foreach ($versions as $version) {
unset($version['path']);
}
\OCP\JSON::success(array('data' => array('versions' => $versions, 'endReached' => $endReached)));
} else {

View File

@ -73,12 +73,13 @@
},
parse: function(result) {
var fullPath = this._fileInfo.getFullPath();
var results = _.map(result.data.versions, function(version) {
var revision = parseInt(version.version, 10);
return {
id: revision,
name: version.name,
fullPath: version.path,
fullPath: fullPath,
timestamp: revision,
size: version.size
};