RFC: carddav: make principal path a DAV:collection #87
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
While not strictly necessary for a pure CardDAV client, this change
allows a plain DAV client to start from the principal path and discover
the home set and within it the addressbook objects.
Example cadaver session:
This did not work before.
While most clients work fine without this, I understand this to be a requirement for this setup to be valid WebDAV (highlighting mine):
Note: This PR is actually mostly to highlight an issue I noticed. Both with and without this change, the code was actually no longer compatible with the old "both user principal URL and home set URL are
/
" approach (I broke it, sorry), because if the two are equal the properties for the latter will never be returned.I initially looked into supporting that, but doing so really complicates things. Imagine this change while keeping that approach working. The code would have to handle:
This would however make the assumption that the home set URL is actually under the principal URL, which I suppose doesn't even have to be the case.
So what to do? I think the questions are:
propfind*()
functions so they can add properties to the same response.Also, maybe you have some other thoughts or ideas? 馃檪