[Peer] cleanup doCount code