We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3cdefc0 commit 3b502acCopy full SHA for 3b502ac
src/main/java/io/ipfs/api/IPFS.java
@@ -423,7 +423,15 @@ public Map ls(Multihash path) throws IOException {
423
// Network commands
424
425
public List<MultiAddress> bootstrap() throws IOException {
426
- return ((List<String>)retrieveMap("bootstrap/").get("Peers")).stream().map(x -> new MultiAddress(x)).collect(Collectors.toList());
+ return ((List<String>)retrieveMap("bootstrap/").get("Peers"))
427
+ .stream()
428
+ .flatMap(x -> {
429
+ try {
430
+ return Stream.of(new MultiAddress(x));
431
+ } catch (Exception e) {
432
+ return Stream.empty();
433
+ }
434
+ }).collect(Collectors.toList());
435
}
436
437
public class Bootstrap {
0 commit comments