You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@couchdb.apache.org by GitBox <gi...@apache.org> on 2020/04/18 18:50:36 UTC

[GitHub] [couchdb-documentation] sztanyoo opened a new pull request #523: Fix PUT attachment documentation

sztanyoo opened a new pull request #523: Fix PUT attachment documentation
URL: https://github.com/apache/couchdb-documentation/pull/523
 
 
   ## Overview
   
   According to https://docs.couchdb.org/en/stable/api/document/attachments.html#put--db-docid-attname Content-Type is a required header in case of adding new attachment.
   However, attachments can be created without specifying the content type
   
   ## Testing recommendations
   
   Create attachment without providing Content-Type header.
   Eg:
   ```
   $ curl -X PUT -v 172.17.0.2:5984/mydatabase/doc4/aab.jpg  --upload-file README.txt 
   { [67 bytes data]
   {"ok":true,"id":"doc4","rev":"1-8a5b4ad6f236295aeb5a52edb8f27470"}
   100  5956  100    67  100  5889   2310   198k --:--:-- --:--:-- --:--:--  207k
   * Closing connection 0
   ```
   
   ## GitHub issue number
   
   Fixes #507 Content-type header is not required when putting attachments
   
   ## Checklist
   
   - [ ] Documentation is written and is accurate;
   - [ ] `make check` passes with no errors
   - [ ] Update [rebar.config.script](https://github.com/apache/couchdb/blob/master/rebar.config.script) with the commit hash once this PR is rebased and merged
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [couchdb-documentation] wohali commented on a change in pull request #523: Fix PUT attachment documentation

Posted by GitBox <gi...@apache.org>.
wohali commented on a change in pull request #523: Fix PUT attachment documentation
URL: https://github.com/apache/couchdb-documentation/pull/523#discussion_r410736485
 
 

 ##########
 File path: src/api/document/attachments.rst
 ##########
 @@ -131,7 +131,7 @@
     :param docid: Document ID
     :param attname: Attachment name
 
-    :<header Content-Type: Attachment MIME type. *Required*
+    :<header Content-Type: Attachment MIME type. Default: "application/octet-stream" *Optional*
 
 Review comment:
   Please add double backticks to correctly format the header, e.g.: ``` Default: ``application/octet-stream`` ```

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [couchdb-documentation] wohali merged pull request #523: Fix PUT attachment documentation

Posted by GitBox <gi...@apache.org>.
wohali merged pull request #523: Fix PUT attachment documentation
URL: https://github.com/apache/couchdb-documentation/pull/523
 
 
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [couchdb-documentation] wohali commented on issue #523: Fix PUT attachment documentation

Posted by GitBox <gi...@apache.org>.
wohali commented on issue #523: Fix PUT attachment documentation
URL: https://github.com/apache/couchdb-documentation/pull/523#issuecomment-615954042
 
 
   @sztanyoo Thank you, Bence, for your first contribution to Apache CouchDB! :parrot: :partying_face: :tada: 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services