Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix trash-bin propfind responses #2821

Merged
merged 2 commits into from
May 4, 2022
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions changelog/unreleased/fix-trashbin-propfind.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
Bugfix: Fix trash-bin propfind responses

Fixed the href of the root element in trash-bin propfind responses.

https://github.com/owncloud/ocis/issues/1846
https://github.com/cs3org/reva/pull/2821
2 changes: 1 addition & 1 deletion internal/http/services/owncloud/ocdav/trashbin.go
Original file line number Diff line number Diff line change
Expand Up @@ -295,7 +295,7 @@ func (h *TrashbinHandler) formatTrashPropfind(ctx context.Context, s *svc, space
responses := make([]*propfind.ResponseXML, 0, len(items)+1)
// add trashbin dir . entry
responses = append(responses, &propfind.ResponseXML{
Href: net.EncodePath(ctx.Value(net.CtxKeyBaseURI).(string) + "/"), // url encode response.Href TODO
Href: net.EncodePath(path.Join(ctx.Value(net.CtxKeyBaseURI).(string), refBase) + "/"), // url encode response.Href TODO
Propstat: []propfind.PropstatXML{
{
Status: "HTTP/1.1 200 OK",
Expand Down