diff --git a/changelog/unreleased/.keep b/changelog/unreleased/.keep new file mode 100644 index 0000000000..e69de29bb2 diff --git a/changelog/unreleased/spaces-capabilities.md b/changelog/unreleased/spaces-capabilities.md new file mode 100644 index 0000000000..9d6d2705b8 --- /dev/null +++ b/changelog/unreleased/spaces-capabilities.md @@ -0,0 +1,5 @@ +Enhancement: Add spaces to the list of capabilities + +In order for clients to be aware of the new spaces feature we need to enable the `spaces` flag on the capabilities' endpoint. As we currently do, the capabilities endpoints remains a hardcoded set of capabilities, and it will default to true. + +https://github.com/cs3org/reva/pull/2015 diff --git a/internal/http/services/owncloud/ocs/data/capabilities.go b/internal/http/services/owncloud/ocs/data/capabilities.go index a50e2983a9..31a23b14e7 100644 --- a/internal/http/services/owncloud/ocs/data/capabilities.go +++ b/internal/http/services/owncloud/ocs/data/capabilities.go @@ -110,6 +110,7 @@ type CapabilitiesDav struct { Trashbin string `json:"trashbin" xml:"trashbin"` Reports []string `json:"reports" xml:"reports>element" mapstructure:"reports"` ChunkingParallelUploadDisabled bool `json:"chunkingParallelUploadDisabled" xml:"chunkingParallelUploadDisabled"` + Spaces bool `json:"spaces" xml:"spaces"` } // CapabilitiesFilesSharing TODO document diff --git a/internal/http/services/owncloud/ocs/handlers/cloud/capabilities/capabilities.go b/internal/http/services/owncloud/ocs/handlers/cloud/capabilities/capabilities.go index 35b7324fb1..a0862059f9 100644 --- a/internal/http/services/owncloud/ocs/handlers/cloud/capabilities/capabilities.go +++ b/internal/http/services/owncloud/ocs/handlers/cloud/capabilities/capabilities.go @@ -116,6 +116,9 @@ func (h *Handler) Init(c *config.Config) { h.c.Capabilities.Dav.Reports = []string{"search-files"} } + // enable spaces by default + h.c.Capabilities.Dav.Spaces = true + // sharing if h.c.Capabilities.FilesSharing == nil {