couchdb-glib cannot store design documents
Bug #830269 reported by
Moses Palmér
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
couchdb-glib |
New
|
Undecided
|
Unassigned |
Bug Description
couchdb-glib constructs resource URLs for individual documents using the format string "%s/%s/%s", which is supplied the CouchDB base URL, the database name and the document ID as format parameters.
The problem is that the document ID is URL encoded before being sent to the function.
For example, the design document "_design/test" in the database "test" on "localhost:123" would receive the URL "localhost:
The attached patch allows any ID that begins with '_' to contain one sublevel and makes it possible to store design documents.
To post a comment you must log in.
I've committed a slightly modified version to git, that uses g_strsplit to get the _* part and use that when building the URL. Thanks a lot for the patch!