Skip to content

Commit

Permalink
Updating network package
Browse files Browse the repository at this point in the history
  • Loading branch information
elielnfinic committed Oct 2, 2024
1 parent 24a0bd0 commit 8fe2ceb
Show file tree
Hide file tree
Showing 11 changed files with 123 additions and 80 deletions.
Binary file modified examples/.DS_Store
Binary file not shown.
Binary file modified examples/canvas/.DS_Store
Binary file not shown.
Binary file modified examples/chat/.DS_Store
Binary file not shown.
Binary file modified examples/grid/.DS_Store
Binary file not shown.
Binary file modified packages/.DS_Store
Binary file not shown.
Binary file modified packages/blueprints/.DS_Store
Binary file not shown.
Binary file modified packages/network/.DS_Store
Binary file not shown.
11 changes: 8 additions & 3 deletions packages/network/src/node.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,12 @@ import type {
URLPeerId,
} from "@libp2p/interface";

import { type KadDHT, type ValueEvent, kadDHT } from "@libp2p/kad-dht";
import {
type KadDHT,
type ValueEvent,
kadDHT,
removePublicAddressesMapper,
} from "@libp2p/kad-dht";
import { peerIdFromString } from "@libp2p/peer-id";
import { pubsubPeerDiscovery } from "@libp2p/pubsub-peer-discovery";
import { webRTC, webRTCDirect } from "@libp2p/webrtc";
Expand Down Expand Up @@ -82,7 +87,7 @@ export class TopologyNetworkNode {
addresses: {
listen: this._config?.addresses ? this._config.addresses : ["/webrtc"],
},
connectionEncrypters: [noise()],
connectionEncrypters: [noise()],
connectionGater: {
denyDialMultiaddr: () => {
return false;
Expand All @@ -106,7 +111,7 @@ export class TopologyNetworkNode {
autonat: autoNAT(),
dcutr: dcutr(),
identify: identify(),
dht: kadDHT(),
dht: kadDHT({}),
pubsub: gossipsub(),
},
streamMuxers: [yamux()],
Expand Down
Binary file modified packages/node/.DS_Store
Binary file not shown.
Binary file modified packages/object/.DS_Store
Binary file not shown.
Loading

0 comments on commit 8fe2ceb

Please sign in to comment.