diff --git a/examples/src/main/javascript/demo.js b/examples/src/main/javascript/demo.js index f3e605311..d8053973f 100644 --- a/examples/src/main/javascript/demo.js +++ b/examples/src/main/javascript/demo.js @@ -56,8 +56,7 @@ bcj.utils.BriefLogFormatter.init(); var PeerGroup = bcj.core.PeerGroup; var pg = new PeerGroup(params) pg.addPeerDiscovery(new bcj.net.discovery.DnsDiscovery(params)); -pg.startAsync(); -pg.awaitRunning(); +pg.start(); // Wait until we have at least three peers. print("Waiting for some peers")