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

carddav: switch to one static path layout #101

Merged
merged 1 commit into from
Nov 2, 2022

Conversation

bitfehler
Copy link
Collaborator

See #100 for details. Obsoletes #99.

resourceTypeUserPrincipal resourceType = iota
resourceTypeAddressBookHomeSet resourceType = iota
resourceTypeAddressBook resourceType = iota
resourceTypeAddressObject resourceType = iota
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: only the first resourceType = iota is necessary, the rest can be omitted.

@bitfehler bitfehler force-pushed the bitfehler/static-path-layout branch from 6dacd83 to ddcb9c0 Compare September 29, 2022 09:20
@bitfehler bitfehler marked this pull request as ready for review September 29, 2022 09:21
@bitfehler
Copy link
Collaborator Author

So, if I recall our discussion correctly, going for a static path layout is probably the most agreeable solution of the bunch, is that correct? For this PR, I added the option to define a global prefix (if your webdav root is not /) based on which a fixed layout is expected. The advantage is that the backend does not have to deal with the "resource type", so the interface stays simple. The code gets a little longer, but stays pretty easy to follow in my opinion. I also added a test. Would love to hear your opinion on this 🙂

@emersion emersion merged commit 561012d into emersion:master Nov 2, 2022
@emersion
Copy link
Owner

emersion commented Nov 2, 2022

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants