couchdb-nano.git
7 weeks agogeneral dependency bump (#294) main v10.0.0
Glynn Bird [Fri, 25 Mar 2022 09:35:31 +0000 (09:35 +0000)] 
general dependency bump (#294)

Co-authored-by: Glynn Bird <glynnbird@apache.org>
4 months agoReplace or remove README deadlinks (#290)
Brennan Fox [Tue, 11 Jan 2022 08:55:00 +0000 (03:55 -0500)] 
Replace or remove README deadlinks (#290)

4 months agoRemove superfluous trailing whitespace & correct typos (#288)
Brennan Fox [Fri, 7 Jan 2022 08:50:11 +0000 (03:50 -0500)] 
Remove superfluous trailing whitespace & correct typos (#288)

4 months agoAdd include_docs to DocumentFetchParams typescript definition, as mentioned in https...
sziladriana [Tue, 21 Dec 2021 10:02:28 +0000 (11:02 +0100)] 
Add include_docs to DocumentFetchParams typescript definition, as mentioned in https://github.com/apache/couchdb-nano/tree/2d4bd719e4f08915ed9c0ef7953e901391ce4239#dbpartitionedlistpartitionkey-params-callback (#286)

Co-authored-by: Adriana Beerta <adriana@forion.com>
4 months agoAdd detailed error message (fixes issue #58) (#285)
gboer [Tue, 21 Dec 2021 10:01:25 +0000 (11:01 +0100)] 
Add detailed error message (fixes issue #58) (#285)

* The mocked/unmocked tests do not exist anymore

* Fixes #58: Include additional information when something fails when connecting, to support easier debugging of connection issues

5 months agoAdd docName to TypeScript type definition (#281)
Adrian Pascu [Tue, 23 Nov 2021 10:05:20 +0000 (12:05 +0200)] 
Add docName to TypeScript type definition (#281)

This parameter noted in [the docs](https://github.com/apache/couchdb-nano/tree/2d4bd719e4f08915ed9c0ef7953e901391ce4239#dbinsertdoc-params-callback).

5 months agoProperly escape partition ID's (fixes #283) (#284)
William Swanson [Tue, 23 Nov 2021 10:00:43 +0000 (02:00 -0800)] 
Properly escape partition ID's (fixes #283) (#284)

This is a breaking change, for reasons descibed in that bug report.

7 months agoType update_seq as optional in DocumentViewResponse (#278)
Nate Faber [Wed, 22 Sep 2021 10:51:39 +0000 (12:51 +0200)] 
Type update_seq as optional in DocumentViewResponse (#278)

8 months ago9.0.5 v9.0.5
Glynn Bird [Tue, 14 Sep 2021 08:20:26 +0000 (09:20 +0100)] 
9.0.5

8 months agofix multipart/related requests when uploading multiple attachments. Fixes issue#238...
Glynn Bird [Mon, 13 Sep 2021 14:42:14 +0000 (15:42 +0100)] 
fix multipart/related requests when uploading multiple attachments. Fixes issue#238 (#279)

Co-authored-by: Glynn Bird <glynnbird@apache.org>
8 months ago9.0.4 v9.0.4
Glynn Bird [Thu, 2 Sep 2021 10:45:05 +0000 (11:45 +0100)] 
9.0.4

8 months agodocument custom certification authority in README
Glynn Bird [Wed, 1 Sep 2021 15:11:39 +0000 (16:11 +0100)] 
document custom certification authority in README

8 months agoensure requestDefaults.headers is used correctly. Fixes issue #273 (#277)
Glynn Bird [Wed, 1 Sep 2021 14:01:58 +0000 (15:01 +0100)] 
ensure requestDefaults.headers is used correctly. Fixes issue #273 (#277)

Co-authored-by: Glynn Bird <glynnbird@apache.org>
8 months agoto avoid circular references (#275)
Glynn Bird [Wed, 1 Sep 2021 09:33:31 +0000 (10:33 +0100)] 
to avoid circular references (#275)

* use selective attribute copy instead of clone to avoid circular references - fixes issue #274

* add a couple of tests to prevent circular references silently regressing

Co-authored-by: Glynn Bird <glynnbird@apache.org>
8 months agoUpdate nano.js (#270)
Samuel Bodin [Wed, 25 Aug 2021 09:58:07 +0000 (11:58 +0200)] 
Update nano.js (#270)

9 months agoMerge pull request #272 from neighbourhoodie/docs-db-create-options
Jan Lehnardt [Thu, 12 Aug 2021 09:32:23 +0000 (11:32 +0200)] 
Merge pull request #272 from neighbourhoodie/docs-db-create-options

Document the options to `db.create()`

9 months agoDocument the options to `db.create()` 272/head
James Coglan [Tue, 10 Aug 2021 12:44:53 +0000 (13:44 +0100)] 
Document the options to `db.create()`

In the source code, the `createDb()` function accepts an options object
but this is not documented. The `PUT /{db}` endpoint [1] does have some
query string options and `nano` users should be able to make use of
them.

[1]: https://docs.couchdb.org/en/stable/api/database/common.html#put--db

14 months agoscrub all requests and auth header, fix changeReader stall - fixes #255, #257 (#256)
Fanie Oosthuysen [Thu, 25 Feb 2021 09:19:11 +0000 (11:19 +0200)] 
scrub all requests and auth header, fix changeReader stall - fixes #255, #257 (#256)

* scrub all requests and auth header - fixes #255

* change changeReader to max out retry back-off at one minute, instead of infinite - fixes #257

* also scrub URL for response headers - #256

14 months agoAdd type definitions for changesReader methods (#258)
Kel Phillipson [Wed, 24 Feb 2021 09:22:11 +0000 (01:22 -0800)] 
Add type definitions for changesReader methods (#258)

Adds missing definitions for pause() and resume() methods that
are present in the documentation and nano.js implementation.

15 months agolog before adding agents - fixes issue #252 (#253) 9.0.3
Glynn Bird [Fri, 15 Jan 2021 07:24:30 +0000 (07:24 +0000)] 
log before adding agents - fixes issue #252 (#253)

Co-authored-by: Glynn Bird <glynnbird@apache.org>
16 months ago9.0.2prep (#251) 9.0.2
Glynn Bird [Wed, 13 Jan 2021 08:19:33 +0000 (08:19 +0000)] 
9.0.2prep (#251)

* more verbose TypeScript descriptions and links

* ensure creds are scrubbed from logged messages

* improved README

* convert examples to async/await style

Co-authored-by: Glynn Bird <glynnbird@apache.org>
16 months agoprepare 9.0.2 release
Glynn Bird [Fri, 8 Jan 2021 09:38:07 +0000 (09:38 +0000)] 
prepare 9.0.2 release

16 months agoPropagate axios errors 236 (#246)
Byron Murgatroyd [Fri, 8 Jan 2021 09:15:02 +0000 (09:15 +0000)] 
Propagate axios errors 236 (#246)

* Propagate axios errors to stream client

Fixes issue #236.

When calling an *AsStream method a client needs to handle errors
raised by couch. These errors can include retrieving an attachment
that doesn't exist or querying a deleted view.

* Removing extra blank line

* Correcting README stream function names

The examples of several stream functions we not named *AsStream.

Co-authored-by: Byron Murgatroyd <byron@omanom.com>
16 months agoConvert nano.d.ts comments to JSDoc (#250)
Jean-Christophe Hoelt [Thu, 7 Jan 2021 09:03:12 +0000 (11:03 +0200)] 
Convert nano.d.ts comments to JSDoc (#250)

16 months agoFix cookie/session support in Nano 9 (#245)
Glynn Bird [Wed, 6 Jan 2021 09:48:22 +0000 (09:48 +0000)] 
Fix cookie/session support in Nano 9 (#245)

* Save authentication cookie after calling nano.auth

nano.auth has no effect if session cookie is not saved correctly so it can be reused in next request.

* Add closing )

* Comply with coding standard

* Comply with coding standard, added missing space after function

* Check that cookie is set after calling nano.auth in test case.

* Wrap in promise

* alternative to pr #242 using toughcookie library for axios

Co-authored-by: Robert Michalski <robmi87@gmail.com>
Co-authored-by: Robert Michalski <robert@surveylegend.com>
Co-authored-by: Glynn Bird <glynnbird@apache.org>
16 months agoAdd RequestError typescript definition (#248)
Jean-Christophe Hoelt [Wed, 6 Jan 2021 09:46:58 +0000 (11:46 +0200)] 
Add RequestError typescript definition (#248)

Errors triggered by nano are extended with additional fields, this commits adds
the typescript definition for them.

The name "RequestError" was chosen because it seems like it all nano errors are
triggered by a request (a 'socket' or a 'couch' error).

I considered "NanoError", but the full type `nano.NanoError` doesn't sound
better than `nano.RequestError` and no other interface have been prefixed with
"Nano".

16 months agoFix invalid parameters error stack trace (#244)
Sam Holmes [Mon, 21 Dec 2020 09:10:55 +0000 (01:10 -0800)] 
Fix invalid parameters error stack trace (#244)

16 months agoFix link to changesReader in toc (#239)
François de Campredon [Thu, 17 Dec 2020 16:29:28 +0000 (17:29 +0100)] 
Fix link to changesReader in toc (#239)

17 months agofix RequestDefaultOptions TypeScript definitions as per issue #240 (#241)
Glynn Bird [Mon, 14 Dec 2020 13:08:12 +0000 (13:08 +0000)] 
fix RequestDefaultOptions TypeScript definitions as per issue #240 (#241)

Co-authored-by: Glynn Bird <glynnbird@apache.org>
18 months agoadded .asf.yaml for repository config (#237)
Glynn Bird [Tue, 10 Nov 2020 08:32:11 +0000 (08:32 +0000)] 
added .asf.yaml for repository config (#237)

Co-authored-by: Glynn Bird <glynnbird@apache.org>
18 months ago9.0.1 v9.0.1
Glynn Bird [Mon, 9 Nov 2020 08:34:35 +0000 (08:34 +0000)] 
9.0.1

18 months agoensure only one HttpAgent is created (not one per request) - fixes issue #234 (#235)
Glynn Bird [Mon, 9 Nov 2020 08:32:15 +0000 (08:32 +0000)] 
ensure only one HttpAgent is created (not one per request) - fixes issue #234 (#235)

Co-authored-by: Glynn Bird <glynnbird@apache.org>
18 months agoremove old migration guide 9.0.0
Glynn Bird [Wed, 4 Nov 2020 14:45:20 +0000 (14:45 +0000)] 
remove old migration guide

18 months ago9.0.0 README
Glynn Bird [Wed, 4 Nov 2020 14:43:55 +0000 (14:43 +0000)] 
9.0.0 README

18 months agoReplace request with axios (#208)
Glynn Bird [Tue, 3 Nov 2020 16:12:42 +0000 (16:12 +0000)] 
Replace request with axios (#208)

* use new url.URL instead of url.parse/url.reslove

* remove mocha tests

* add jest framework. Remove tape/mocha/istanbul.

* first jest tests

* finished top level tests

* document tests complete

* design functions

* multipart tests

* attachment tests

* tidy up

* auth/session/uuids

* 100% coverage

* partitioned functions and tests

* tidy up

* standard styling of examples

* only support current versions of node

* stash changes

* remove db.copy function - axios does not support COPY HTTP method

* alter the way attachment.insertAsStream works

* typescript update

* combine attachment.insert attachment.insertAsStream

* ensure db.head passes the test

* configure default http agent, user-agent string and gzipping

* added tests for gzip/user-agent headers + TypeScript defs

* ensure tests run in env=node mode

* typescript defs

* remove cloudant-follow and replace with changesReader

* added further tests

* readme

* removed errs dependency

* resurrect logging

* get changesreader to use relax

* fixed suggestions from @eridal

* avoid extra function wrapper in setTimeout

* handle numeric sequence tokens

* remove callback from wait:true mode - switch to pause()/resume() functions

* ensure the response attributes are assigned to the error object thrown

* add description to error messages

* prevent Error message being overwritten

* dependency bump

* ensure Node version list matches current/supported versions

* fixup readme

* fix(nano.d.ts): add opts and callback for relax (#225)

* fix(nano.d.ts): add opts and callback for nano.request

* fix(nano.d.ts): add opts and callback for relax and dinosaur

* Add FollowEmitter.stop() to typescript declaration file (#230)

* Patch typescript declaration file (#231)

* Add string to View.map type (#220)

addresses #219

* - Addded viewWithListAsStream function (#227)

- Added test case for viewWithListAsStream
- Added documntation for viewWithListm and viewWithListAsStream

* dependency bump

* updated Node.js versions used to test to reflect current supported versions

* standard fixes

* added 8->9 migration guide

Co-authored-by: Glynn Bird <glynnbird@apache.org>
Co-authored-by: Steven Tang <steven.yc.tang@gmail.com>
Co-authored-by: Leon <sxwei123@users.noreply.github.com>
Co-authored-by: Luiz Victor Linhares Rocha <luizvictorlrocha@gmail.com>
Co-authored-by: Luca Morandini <lmorandini@ieee.org>
18 months ago8.2.3 v8.2.3
Glynn Bird [Mon, 2 Nov 2020 16:04:43 +0000 (16:04 +0000)] 
8.2.3

18 months ago8.2.2
Glynn Bird [Mon, 2 Nov 2020 16:02:44 +0000 (16:02 +0000)] 
8.2.2

18 months agomaster --> main (#232)
Glynn Bird [Mon, 2 Nov 2020 14:30:15 +0000 (14:30 +0000)] 
master --> main (#232)

* fix(nano.d.ts): add opts and callback for relax (#225)

* fix(nano.d.ts): add opts and callback for nano.request

* fix(nano.d.ts): add opts and callback for relax and dinosaur

* Add FollowEmitter.stop() to typescript declaration file (#230)

* Patch typescript declaration file (#231)

* Add string to View.map type (#220)

addresses #219

* - Addded viewWithListAsStream function (#227)

- Added test case for viewWithListAsStream
- Added documntation for viewWithListm and viewWithListAsStream

Co-authored-by: Steven Tang <steven.yc.tang@gmail.com>
Co-authored-by: Leon <sxwei123@users.noreply.github.com>
Co-authored-by: Luiz Victor Linhares Rocha <luizvictorlrocha@gmail.com>
Co-authored-by: Luca Morandini <lmorandini@ieee.org>
23 months agoMerge pull request #226 from YC/info
Jan Lehnardt [Wed, 10 Jun 2020 17:09:14 +0000 (19:09 +0200)] 
Merge pull request #226 from YC/info

Add nano.info()

23 months agoAdd nano.info() 226/head
Steven Tang [Tue, 9 Jun 2020 11:35:05 +0000 (21:35 +1000)] 
Add nano.info()

2 years agoimprove MangoSelector TypeScript type - fixes issue #211 (#212)
Glynn Bird [Tue, 3 Mar 2020 13:12:18 +0000 (13:12 +0000)] 
improve MangoSelector TypeScript type - fixes issue #211 (#212)

2 years ago8.2.1 v8.2.1
Glynn Bird [Mon, 2 Mar 2020 08:20:16 +0000 (08:20 +0000)] 
8.2.1

2 years agodo not publish tests in npm package
Glynn Bird [Mon, 2 Mar 2020 08:19:47 +0000 (08:19 +0000)] 
do not publish tests in npm package

2 years agostricter TypeScript definitions with tsc --strict, fixes issue #209 (#210)
Glynn Bird [Sun, 1 Mar 2020 10:15:01 +0000 (10:15 +0000)] 
stricter TypeScript definitions with tsc --strict, fixes issue #209 (#210)

2 years agoFix markdown link in the menu
Glynn Bird [Fri, 28 Feb 2020 09:46:53 +0000 (09:46 +0000)] 
Fix markdown link in the menu

2 years agoallow fetch to return errors as well as successes - fixes issue #203 (#204) 8.2.0
Glynn Bird [Thu, 27 Feb 2020 13:32:42 +0000 (13:32 +0000)] 
allow fetch to return errors as well as successes - fixes issue #203 (#204)

2 years agoimprove TypeScript definitions for Mango selectors - fixes issue #202 (#205)
Glynn Bird [Thu, 27 Feb 2020 13:32:21 +0000 (13:32 +0000)] 
improve TypeScript definitions for Mango selectors - fixes issue #202 (#205)

2 years agofixed TypeScript definitions for follow functions - fixes issue #194 (#206)
Glynn Bird [Thu, 27 Feb 2020 13:31:53 +0000 (13:31 +0000)] 
fixed TypeScript definitions for follow functions - fixes issue #194 (#206)

2 years agoswitch to CouchDB 3 for the Travis tests - no admin party in CouchDB 3 (#207)
Glynn Bird [Thu, 27 Feb 2020 12:45:55 +0000 (12:45 +0000)] 
switch to CouchDB 3 for the Travis tests - no admin party in CouchDB 3 (#207)

2 years agocompatibility with nodejs-cloudant
Glynn Bird [Mon, 17 Feb 2020 09:51:43 +0000 (09:51 +0000)] 
compatibility with nodejs-cloudant

2 years agoensure TypeScript definitions are sound during testing (#201)
Glynn Bird [Mon, 17 Feb 2020 09:07:36 +0000 (09:07 +0000)] 
ensure TypeScript definitions are sound during testing (#201)

2 years agoMake sure nano works with _local docs (#200)
Glynn Bird [Thu, 13 Feb 2020 18:07:00 +0000 (18:07 +0000)] 
Make sure nano works with _local docs (#200)

* added test to fetch local docs

* _local support added #167

* added local tests

Co-authored-by: Malte Legenhausen <mlegenhausen@gmail.com>
Thanks @mlegenhausen!

2 years agoBugfix (nano.d.ts): DocumentScope.atomic method returns a customizable data structure...
Kyle Chine [Thu, 13 Feb 2020 14:08:24 +0000 (00:08 +1000)] 
Bugfix (nano.d.ts): DocumentScope.atomic method returns a customizable data structure (#187)

* bugfix: DocumentScope.atomic returns a customizable response

* add my name as contributor

2 years agoBugfix(README.md): Fixed typo (#188)
Philipp [Thu, 13 Feb 2020 14:05:54 +0000 (15:05 +0100)] 
Bugfix(README.md): Fixed typo (#188)

PASSSWORD => PASSWORD

2 years agoFix for issue 189 (#190)
Belisarith [Thu, 13 Feb 2020 14:05:23 +0000 (15:05 +0100)] 
Fix for issue 189 (#190)

2 years agotypescript definition for built-in reduce function in view's document (#192)
Felipe Roberto [Thu, 13 Feb 2020 14:03:21 +0000 (11:03 -0300)] 
typescript definition for built-in reduce function in view's document (#192)

2 years agochange bulk() return type (#199)
Agnaro [Thu, 13 Feb 2020 14:02:02 +0000 (09:02 -0500)] 
change bulk() return type (#199)

2 years agoAutomated test rewrite + addition of partitioned functions (#197)
Glynn Bird [Thu, 13 Feb 2020 13:11:48 +0000 (13:11 +0000)] 
Automated test rewrite + addition of partitioned functions (#197)

* use new url.URL instead of url.parse/url.reslove

* remove mocha tests

* add jest framework. Remove tape/mocha/istanbul.

* first jest tests

* finished top level tests

* document tests complete

* design functions

* multipart tests

* attachment tests

* tidy up

* auth/session/uuids

* 100% coverage

* partitioned functions and tests

* tidy up

* standard styling of examples

* only support current versions of node

* const { URL } trick

* removed async from tests that return Promises

* another async test

* reduce code duplication per @garrensmiths review

2 years agoFix typo (#177)
B͈̤̖̪̪̱ͅl̯̯̮̼͎̬͚̳̩̖̲u̜̼͉͈̠b͙̬̘̙̱̗̲͙b͍̞̬̬͓̼l̰̪͖̯̼̟̟͈̖͕̜̱̜ͅl̻̗͔̝̭̰͚͇̯̥ [Wed, 4 Sep 2019 07:05:39 +0000 (09:05 +0200)] 
Fix typo (#177)

'authenication'

2 years agoget attachment should return a Buffer (#173)
Glynn Bird [Mon, 8 Jul 2019 07:24:12 +0000 (08:24 +0100)] 
get attachment should return a Buffer (#173)

2 years agofix(nano.d.ts): fix MangoSelector typings (#172)
ilatovsky [Thu, 4 Jul 2019 11:34:29 +0000 (14:34 +0300)] 
fix(nano.d.ts): fix MangoSelector typings (#172)

3 years agoadd replication to dbScope ts interface (#163)
Vincze Dániel [Tue, 7 May 2019 13:14:42 +0000 (15:14 +0200)] 
add replication to dbScope ts interface (#163)

3 years agoAdded types for db.createIndex. Fixes #129 (#161)
Lester Pérez [Tue, 7 May 2019 08:08:59 +0000 (10:08 +0200)] 
Added types for db.createIndex. Fixes #129 (#161)

* Added types for db.createIndex. Fixes #129

* Added field 'partitioned' to CreateIndexRequest

* Partitioned made optional

3 years agoPrepare8.1.0 (#160) 8.1.0
Glynn Bird [Thu, 2 May 2019 14:53:18 +0000 (15:53 +0100)] 
Prepare8.1.0 (#160)

* prepare for v8.1.0 - dependency version bump

* avoid deploying tests and scripts

* new, improved  package-lock.json

* new linting standards applied

* new linting standards applied for nano.js

3 years agoWhen docs are included, returned objects are expected to be documents (#153)
Mickael Lecoq [Thu, 2 May 2019 14:22:14 +0000 (16:22 +0200)] 
When docs are included, returned objects are expected to be documents (#153)

3 years agoFix typo (#151)
Evan Li [Thu, 2 May 2019 14:21:29 +0000 (10:21 -0400)] 
Fix typo (#151)

3 years agoUpdate nano.d.ts (#155)
Samriddhi [Thu, 2 May 2019 14:20:59 +0000 (07:20 -0700)] 
Update nano.d.ts (#155)

Adding null to the MangoValue

3 years agoSupport database create params. (#158)
Sam Smith [Thu, 2 May 2019 14:07:23 +0000 (15:07 +0100)] 
Support database create params. (#158)

3 years agoPost search queries (#157)
Sam Smith [Thu, 2 May 2019 13:52:17 +0000 (14:52 +0100)] 
Post search queries (#157)

* Submit all search queries via POST.

* Expose `baseView` function.

3 years agoprepare v8.0.1 release
Glynn Bird [Mon, 18 Mar 2019 08:38:25 +0000 (08:38 +0000)] 
prepare v8.0.1 release

3 years ago8.0.1 v8.0.1
Glynn Bird [Mon, 18 Mar 2019 08:33:10 +0000 (08:33 +0000)] 
8.0.1

3 years agoFix typo (#143)
Björn Tegelund [Mon, 18 Mar 2019 08:31:54 +0000 (17:31 +0900)] 
Fix typo (#143)

3 years agoReadme 📝: typo, missing comma (#140)
fdenzer [Mon, 18 Mar 2019 08:30:44 +0000 (09:30 +0100)] 
Readme 📝: typo, missing comma (#140)

* fix typo in readme

rabbit previously written with superfluous, second `t`at the end

* readme: coma was missing in samples

in two examples, there was no coma between
`find( {fields … `
and
`… limit })`

This commit fixed it, as it is invalid JavaScript

3 years agoRemove lodash.isEmpty from dependencies (#123)
Angelos Chalaris [Mon, 18 Mar 2019 08:30:10 +0000 (10:30 +0200)] 
Remove lodash.isEmpty from dependencies (#123)

3 years agoFix for Issue148 - handling of drilldown parameter for search (#149)
Glynn Bird [Mon, 18 Mar 2019 08:28:21 +0000 (08:28 +0000)] 
Fix for Issue148 - handling of drilldown parameter for search (#149)

* fix formatting of drilldown parameter for issue #148

* added tests

* added README for drilldown parameter

3 years ago8.0.0 v8.0.0
Glynn Bird [Wed, 9 Jan 2019 10:55:43 +0000 (10:55 +0000)] 
8.0.0

3 years ago141 stream callbacks (#142)
Rich Ellis [Wed, 9 Jan 2019 10:51:46 +0000 (10:51 +0000)] 
141 stream callbacks (#142)

* Removed callbacks from *AsStream functions

Updated function signataures.
Refactored stream tests to not use callbacks.

* Updated package-lock file

* Corrected travis test running

Moved execution of travis scripts to .travis.yml.
Removing scripts from around npm test allows travis
script step to fail when tests fail.
Combined tests and linting with `&&` so that both need to pass.

* Corrected linter failures unrelated to proposed change

* Fixed copyDoc behaviour for promises in overwrite case

3 years agokeys can be set as array (#135)
Mickael Lecoq [Mon, 17 Dec 2018 08:05:24 +0000 (09:05 +0100)] 
keys can be set as array (#135)

3 years agoprepare for 7.1.1 (#133)
Glynn Bird [Wed, 14 Nov 2018 07:20:08 +0000 (07:20 +0000)] 
prepare for 7.1.1 (#133)

3 years agoFix doc errors (#132)
码日光 [Wed, 14 Nov 2018 07:11:34 +0000 (15:11 +0800)] 
Fix doc errors (#132)

3 years agoPass request agent to cloudant-follow (#128)
Sam Smith [Wed, 14 Nov 2018 07:10:25 +0000 (07:10 +0000)] 
Pass request agent to cloudant-follow (#128)

* Pass request agent to cloudant-follow

* Use cloudant-follow 0.18.0

3 years agoOnly return Promise from `headDoc` when no callback is specified. (#130)
Sam Smith [Wed, 14 Nov 2018 07:04:12 +0000 (07:04 +0000)] 
Only return Promise from `headDoc` when no callback is specified. (#130)

3 years agoFix typo in README code samples (#125)
Frederik Ring [Wed, 3 Oct 2018 12:56:30 +0000 (14:56 +0200)] 
Fix typo in README code samples (#125)

3 years ago7.1.0
Glynn Bird [Tue, 18 Sep 2018 10:40:09 +0000 (11:40 +0100)] 
7.1.0

3 years agoremoved spatial function - fixes issue #103 (#117)
Glynn Bird [Tue, 21 Aug 2018 11:41:02 +0000 (12:41 +0100)] 
removed spatial function - fixes issue #103 (#117)

3 years agoUpdate anchor tags to attachments documentation (#115)
Piotr Zarzycki [Mon, 20 Aug 2018 09:53:56 +0000 (11:53 +0200)] 
Update anchor tags to attachments documentation (#115)

3 years agoStandard linter (#116)
Glynn Bird [Mon, 20 Aug 2018 09:52:25 +0000 (10:52 +0100)] 
Standard linter (#116)

Implement "standard" JS standard.

3 years agoFIX update handler example code fixes #110 (#111)
necipallef [Tue, 14 Aug 2018 13:45:54 +0000 (16:45 +0300)] 
FIX update handler example code fixes #110 (#111)

3 years agoSome typescript fixes (#108)
jlami [Tue, 14 Aug 2018 13:38:42 +0000 (15:38 +0200)] 
Some typescript fixes (#108)

3 years agofeat: remove endswith dependency in favour of ES6 String.endsWith (#106)
Jan Lehnardt [Tue, 14 Aug 2018 13:35:17 +0000 (15:35 +0200)] 
feat: remove endswith dependency in favour of ES6 String.endsWith (#106)

* wip: stop depending on tape-it

tape-it should have moved over with nano, it’s a tape harness config,
but binds us to an old version of tape. I tried a simple copy and paste,
while keeping the tape version, but getting npm t issues. This is a
three-step process:

1. copy `dscape/tape-it/index.js` to `test/helpers/harness.js`
2. update the `require` in `test/helpers/integration.js`
3. make tests work

It leads us to the fun situation where our integration tests are run with
tape version ^3.0.1 and the rest with 4.6.2.

* feat: remove endswith dependency in favour of ES6 String.endsWith

3 years agowip: stop depending on tape-it (#105)
Jan Lehnardt [Tue, 14 Aug 2018 13:28:14 +0000 (15:28 +0200)] 
wip: stop depending on tape-it (#105)

tape-it should have moved over with nano, it’s a tape harness config,
but binds us to an old version of tape. I tried a simple copy and paste,
while keeping the tape version, but getting npm t issues. This is a
three-step process:

1. copy `dscape/tape-it/index.js` to `test/helpers/harness.js`
2. update the `require` in `test/helpers/integration.js`
3. make tests work

It leads us to the fun situation where our integration tests are run with
tape version ^3.0.1 and the rest with 4.6.2.

3 years agoPrevent callback users seeing Promise rejections (#113)
Glynn Bird [Tue, 14 Aug 2018 11:58:38 +0000 (12:58 +0100)] 
Prevent callback users seeing Promise rejections (#113)

* 7.0.0

* prevent callback users seeing Promise rejections - fixes issue #112

* only return a Promise when no callback specfied and refactor tests to only test callback or promise, not both.

3 years agoMerge pull request #80 from adamsaeid/multi-view-queries
Jan Lehnardt [Tue, 24 Jul 2018 15:37:05 +0000 (17:37 +0200)] 
Merge pull request #80 from adamsaeid/multi-view-queries

Multi view queries tests

3 years agoPromise support for Nano - Issue 98 (#102)
Glynn Bird [Tue, 24 Jul 2018 11:19:55 +0000 (12:19 +0100)] 
Promise support for Nano - Issue 98 (#102)

* package-lock.json audit fix

* return Promise by default

* tests passing

* amend integration/document tests wrt Promise return values

* amend integration/attachment tests wrt Promise return values

* amend integration/database tests wrt Promise return values

* amend integration/design tests wrt Promise return values

* amend integration/multipart tests wrt Promise return values

* amend integration/shared tests wrt Promise return values

* amend integration/util tests wrt Promise return values

* amend intercept/design tests wrt Promise return values

* readme rewrite

* first stab at TypeScript definition returning Promises

* added ...AsStream varaiants

* add TypeScript to the README

* test fix

* find query missing from README

* added findAsStream and find tests

* added searchAsStream

* searchAsStream README

* add viewAsStream

* added changesAsStream

* fix tests

* add migration guide from nano 6 to nano 7

* tests and jshint work

* 99+% test coverage

* migration guide

* swap out var for const/let in the core code and tests

* refactor responseHandler to make parameter names more readable

* add default parameter value in responseHandler

* return headers for headDoc on an error

* added central getCallback function to remove code duplication

* var--->const in the README

* modernise JS in migration guide

* jshint fixes

* further documentation changes after feedback from @janl

* use official CouchDB docker image at the suggestion of @wohali

3 years agoFix merge conflicts for #80 80/head
Adam Saeid [Mon, 23 Jul 2018 18:12:14 +0000 (19:12 +0100)] 
Fix merge conflicts for #80

3 years agoFix JSON.stringify of start_key & end_key alias parameters (#93)
Glynn Bird [Mon, 2 Jul 2018 14:03:45 +0000 (15:03 +0100)] 
Fix JSON.stringify of start_key & end_key alias parameters (#93)

* 6.4.4

* ensure start_key & end_key parameters are JSON.stringified - fixes issue #92

* fix mocked tests

3 years agoclone user-supplied query string object prior to mutation - issue #85 (#95)
Glynn Bird [Mon, 2 Jul 2018 14:03:21 +0000 (15:03 +0100)] 
clone user-supplied query string object prior to mutation - issue #85 (#95)

* clone use-supplied query string object prior to mutation - fixes issue #85

* use Object.assign to clone object

* save line of code and qs->qs1

3 years agoadd TypeScript definition in this repo - issue #77 (#96)
Glynn Bird [Mon, 2 Jul 2018 13:08:08 +0000 (14:08 +0100)] 
add TypeScript definition in this repo - issue #77 (#96)

* add typescript definition in this repo - issue #77

* add package-lock.json too

3 years agofix link to cloudant-follow in the README.md as per issue #81 (#94)
Glynn Bird [Mon, 2 Jul 2018 13:05:14 +0000 (14:05 +0100)] 
fix link to cloudant-follow in the README.md as per issue #81 (#94)

3 years agoFix documentation url related to Attachment (#99)
Piotr Zarzycki [Mon, 2 Jul 2018 13:04:42 +0000 (15:04 +0200)] 
Fix documentation url related to Attachment (#99)