Skip to content

Commit

Permalink
(pouchdb#7127) Fix docs for db.query()'s options.reduce default
Browse files Browse the repository at this point in the history
  • Loading branch information
alxndrsn committed Mar 6, 2018
1 parent 64894da commit d9b2db3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion docs/_includes/api/query_database.html
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
* A full CouchDB-style map/reduce view: `{map : ..., reduce: ...}`.
* A map function by itself (no reduce).
* The name of a view in an existing design document (e.g. `'mydesigndoc/myview'`, or `'myview'` as a shorthand for `'myview/myview'`).
* `options.reduce`: Reduce function, or the string name of a built-in function: `'_sum'`, `'_count'`, or `'_stats'`. Defaults to `false` (no reduce).
* `options.reduce`: Reduce function, or the string name of a built-in function: `'_sum'`, `'_count'`, or `'_stats'`. Defaults to `true` when a reduce function is defined, or `false` otherwise.
* Tip: if you're not using a built-in, [you're probably doing it wrong](http://youtu.be/BKQ9kXKoHS8?t=865s).
* PouchDB will always call your reduce function with rereduce == false. As for CouchDB, refer to the [CouchDB documentation](http://docs.couchdb.org/en/1.6.1/couchapp/views/intro.html).
* `options.include_docs`: Include the document in each row in the `doc` field.
Expand Down

0 comments on commit d9b2db3

Please sign in to comment.