@@ -22,8 +22,7 @@ import {
22
22
MAX_IDENTIFY_MESSAGE_SIZE ,
23
23
TIMEOUT ,
24
24
MAX_PUSH_OUTGOING_STREAMS ,
25
- MAX_OBSERVED_ADDRESSES ,
26
- RUN_ON_TRANSIENT_CONNECTION
25
+ MAX_OBSERVED_ADDRESSES
27
26
} from './consts.js'
28
27
import { Identify } from './pb/message.js'
29
28
import type { IdentifyService , IdentifyServiceComponents , IdentifyServiceInit } from './index.js'
@@ -61,7 +60,7 @@ export class DefaultIdentifyService implements Startable, IdentifyService {
61
60
private readonly maxIdentifyMessageSize : number
62
61
private readonly maxObservedAddresses : number
63
62
private readonly events : EventEmitter < Libp2pEvents >
64
- private readonly runOnTransientConnection : boolean
63
+ private readonly runOnTransientConnection ? : boolean
65
64
66
65
constructor ( components : IdentifyServiceComponents , init : IdentifyServiceInit ) {
67
66
this . started = false
@@ -81,7 +80,7 @@ export class DefaultIdentifyService implements Startable, IdentifyService {
81
80
this . maxPushOutgoingStreams = init . maxPushOutgoingStreams ?? MAX_PUSH_OUTGOING_STREAMS
82
81
this . maxIdentifyMessageSize = init . maxIdentifyMessageSize ?? MAX_IDENTIFY_MESSAGE_SIZE
83
82
this . maxObservedAddresses = init . maxObservedAddresses ?? MAX_OBSERVED_ADDRESSES
84
- this . runOnTransientConnection = init . runOnTransientConnection ?? RUN_ON_TRANSIENT_CONNECTION
83
+ this . runOnTransientConnection = init . runOnTransientConnection
85
84
86
85
// Store self host metadata
87
86
this . host = {
0 commit comments