CouchDB
  1. CouchDB
  2. COUCHDB-1101

Headers from update handler not returned when a document is created/modified

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: 1.0.2
    • Fix Version/s: None
    • Component/s: HTTP Interface
    • Labels:
      None
    • Environment:

      Fedora 14, 4 Cores, 4 GB RAM

      Description

      I expect from this update handler to return "X-my-header" header in response. It does not.

      function(doc,req) {
      var resp = { "headers" :

      { "X-my-header": "application" }

      , "body": "" };
      return [{_id:req.uuid}, resp];
      }

      Changing the return to:

      return [null, resp];

      helps.

        Activity

        Jiri Sedlacek created issue -
        Marcos Zanona made changes -
        Field Original Value New Value
        Comment [ Same thing here, this makes the update handler useless for lots of different situations. Since if you return null it won't update/create a document at all. ]
        Alexander Shorin made changes -
        Status Open [ 1 ] Closed [ 6 ]
        Resolution Fixed [ 1 ]

          People

          • Assignee:
            Unassigned
            Reporter:
            Jiri Sedlacek
          • Votes:
            2 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development