Skip to content

Commit

Permalink
Revert "add announce address (#2648)"
Browse files Browse the repository at this point in the history
This reverts commit a90070e.
  • Loading branch information
zeroxbt committed Jul 14, 2023
1 parent 661a53d commit a4aecd1
Showing 1 changed file with 3 additions and 11 deletions.
14 changes: 3 additions & 11 deletions src/modules/network/implementation/libp2p-service.js
Original file line number Diff line number Diff line change
Expand Up @@ -75,14 +75,10 @@ class Libp2pService {
* }
*/
this.sessions = {};
const addresses = {
listen: [`/ip4/0.0.0.0/tcp/${this.config.port}`],
};
if (ip.isV4Format(this.config.publicIp) && ip.isPublic(this.config.publicIp)) {
addresses.announce = [`/ip4/${this.config.publicIp}/tcp/${this.config.port}`];
}
this.node = await createLibp2p({
addresses,
addresses: {
listen: [`/ip4/0.0.0.0/tcp/${this.config.port}`],
},
transports: [tcp()],
streamMuxers: [mplex()],
connectionEncryption: [noise()],
Expand Down Expand Up @@ -175,10 +171,6 @@ class Libp2pService {
this.blackList = {};
}

getConnections(peerIdObject) {
return this.node.getConnections(peerIdObject);
}

getMultiaddrs() {
return this.node.getMultiaddrs();
}
Expand Down

0 comments on commit a4aecd1

Please sign in to comment.