mirror of https://github.com/status-im/go-waku.git
fix:during unsubscribeAll, remove peer without any checks
This commit is contained in:
parent
baeaa1dd55
commit
af7471d158
|
@ -436,9 +436,7 @@ func (wf *WakuFilterLightnode) UnsubscribeAll(ctx context.Context, opts ...Filte
|
|||
localWg.Wait()
|
||||
close(resultChan)
|
||||
for _, peerID := range peersUnsubscribed {
|
||||
if len(wf.subscriptions.items[peerID].subscriptionsPerTopic) == 0 {
|
||||
delete(wf.subscriptions.items, peerID)
|
||||
}
|
||||
delete(wf.subscriptions.items, peerID)
|
||||
}
|
||||
return resultChan, nil
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue