Skip to content

Commit

Permalink
feat: make log as protected (#407)
Browse files Browse the repository at this point in the history
  • Loading branch information
tuyennhv committed Mar 23, 2023
1 parent 5cd8b07 commit 5b3aee9
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/index.ts
Expand Up @@ -353,6 +353,11 @@ export class GossipSub extends EventEmitter<GossipsubEvents> implements PubSub<G
*/
public readonly topicValidators = new Map<TopicStr, TopicValidatorFn>()

/**
* Make this protected so child class may want to redirect to its own log.
*/
protected readonly log: Logger

/**
* Number of heartbeats since the beginning of time
* This allows us to amortize some resource cleanup -- eg: backoff cleanup
Expand All @@ -367,7 +372,6 @@ export class GossipSub extends EventEmitter<GossipsubEvents> implements PubSub<G
private readonly components: GossipSubComponents

private directPeerInitial: ReturnType<typeof setTimeout> | null = null
private readonly log: Logger

public static multicodec: string = constants.GossipsubIDv11

Expand Down

0 comments on commit 5b3aee9

Please sign in to comment.