Skip to content

Commit

Permalink
Fix version restore after pp
Browse files Browse the repository at this point in the history
Co-authored-by: Julian Koberg <[email protected]>

Signed-off-by: Christian Richter <[email protected]>
  • Loading branch information
dragonchaser committed May 9, 2023
1 parent afacd4e commit 150d97b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions changelog/unreleased/fix-version-restore-after-pp.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
Bugfix: Restore last version after positive result

We fixed a bug in the copy routine that prevented restoring of a previous version after post-processing (e.g. virus scanning)

https://github.com/owncloud/enterprise/issues/5709
2 changes: 1 addition & 1 deletion pkg/storage/utils/decomposedfs/upload/upload.go
Original file line number Diff line number Diff line change
Expand Up @@ -370,7 +370,7 @@ func (upload *Upload) cleanup(cleanNode, cleanBin, cleanInfo bool) {
upload.Node = nil
default:

if err := upload.lu.CopyMetadata(upload.Node.InternalPath(), p, func(attributeName string) bool {
if err := upload.lu.CopyMetadata(p, upload.Node.InternalPath(), func(attributeName string) bool {
return strings.HasPrefix(attributeName, prefixes.ChecksumPrefix) ||
attributeName == prefixes.TypeAttr ||
attributeName == prefixes.BlobIDAttr ||
Expand Down

0 comments on commit 150d97b

Please sign in to comment.