move score starting nil check inside the score implementation
This commit is contained in:
parent
ff89a0e619
commit
d5e432a62b
@ -184,10 +184,8 @@ func (gs *GossipSubRouter) Attach(p *PubSub) {
|
||||
gs.p = p
|
||||
gs.tracer = p.tracer
|
||||
|
||||
// start the scoring, if any
|
||||
if gs.score != nil {
|
||||
gs.score.Start(gs)
|
||||
}
|
||||
// start the scoring
|
||||
gs.score.Start(gs)
|
||||
|
||||
// start using the same msg ID function as PubSub for caching messages.
|
||||
gs.mcache.SetMsgIdFn(p.msgID)
|
||||
|
Loading…
x
Reference in New Issue
Block a user