In a multi-query view request, set view type for each query

Namely, a default `reduce` view type can be overridden to behave like a `map`,
if user explicitly sets `reduce=false`.

Previously this didn't happen. For example, a query like this:

```
{
  "queries": [{
    "include_docs": true,
    "reduce": false
  }]
}
```

 would fail with:

```
{"error":"query_parse_error","reason":"`include_docs` is invalid for reduce"}
```

 but it shouldn't, because user explicitly disabled `reduce` and now
`include_docs` is valid for a map view.

To fix, make sure to call `set_view_type` for each query's args.

Jira: COUCHDB-3070
1 file changed
tree: ef7f1132048db20084405ad6be7951082db6cb2c
  1. include/
  2. priv/
  3. src/
  4. test/
  5. .travis.yml
  6. LICENSE