Use Future.successful() when removing peer as there is no underlying async computation (#5394)

This commit is contained in:
Chris Stewart 2024-02-11 11:28:25 -06:00 committed by GitHub
parent 9d58c9eb89
commit 2d3e481ce0
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -267,7 +267,7 @@ case class PeerFinder(
}
def removePeer(peer: Peer): Future[Option[PeerData]] = {
Future {
Future.successful {
logger.debug(s"Removing peer=$peer")
_peerData.remove(peer) //peer must be a member of _peerData
}