From 1ac0722de7fa1fdce3681d1f45bed6bc1322a539 Mon Sep 17 00:00:00 2001 From: Alan Shaw Date: Thu, 14 Nov 2019 13:20:09 +0000 Subject: [PATCH] docs: clarify bootstrap add/remove optional params (#557) --- SPEC/BOOTSTRAP.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/SPEC/BOOTSTRAP.md b/SPEC/BOOTSTRAP.md index 923696a981..ba562a57c4 100644 --- a/SPEC/BOOTSTRAP.md +++ b/SPEC/BOOTSTRAP.md @@ -22,6 +22,8 @@ Although not listed in the documentation, all the following APIs that actually r - `addr` is a [multiaddr](https://github.com/multiformats/js-multiaddr) to a peer node - `options.default` if true, add the default peers to the list +Note: If passing the `default` option, `addr` is an optional parameter (may be `undefined`/`null`) and options may be passed as the first argument. i.e. `ipfs.bootstrap.add({ default: true })` + **Returns** | Type | Description | @@ -89,6 +91,8 @@ A great source of [examples][] can be found in the tests for this API. - `addr` is a [multiaddr](https://github.com/multiformats/js-multiaddr) to a peer node - `options.all` if true, remove all peers from the list +Note: If passing the `all` option, `addr` is an optional parameter (may be `undefined`/`null`) and options may be passed as the first argument. i.e. `ipfs.bootstrap.rm({ all: true })` + **Returns** | Type | Description |