Skip to content

Commit 931e042

Browse files
authored
fix: enable identify service all the time (#1440)
We only enable identify if stream muxers are configured, but new transports can be their own muxers so just enable it all the time.
1 parent f4b1f54 commit 931e042

File tree

1 file changed

+5
-8
lines changed

1 file changed

+5
-8
lines changed

src/libp2p.ts

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -165,14 +165,11 @@ export class Libp2pNode extends EventEmitter<Libp2pEvents> implements Libp2p {
165165
this.components.transportManager.add(this.configureComponent(fn(this.components)))
166166
})
167167

168-
// Attach stream multiplexers
169-
if (init.streamMuxers != null && init.streamMuxers.length > 0) {
170-
// Add the identify service since we can multiplex
171-
this.identifyService = new IdentifyService(this.components, {
172-
...init.identify
173-
})
174-
this.configureComponent(this.identifyService)
175-
}
168+
// Add the identify service
169+
this.identifyService = new IdentifyService(this.components, {
170+
...init.identify
171+
})
172+
this.configureComponent(this.identifyService)
176173

177174
// dht provided components (peerRouting, contentRouting, dht)
178175
if (init.dht != null) {

0 commit comments

Comments
 (0)