couchbase/couchbase-lite-ios — pull request #425 by refractalize (2014-08-22 13:21:03+00:00)
Title: streamed requests return a proper response

This is in relation to this bug in PouchDB: https://github.com/pouchdb/pouchdb/issues/2660

When an AJAX request accesses the `xhr.upload` property, the request turns into a stream, giving the request a `HTTPBodyStream` member, instead of a `HTTPBody` member.

When this happens the request is parsed asynchronously, and the response isn't sent back correctly, resulting in a 0 status on the XHR.

Sounds weird, because of this issue, PouchDB cannot talk to Couchbase Lite on iOS.

This patch returns a proper response when the request is a stream.