From 544348f8ff6438ffb522a6dd4c19b1f46979b313 Mon Sep 17 00:00:00 2001 From: pasta Date: Tue, 26 Mar 2024 18:19:02 -0500 Subject: [PATCH] refactor: add a default for CopyNodeVector(cond) --- src/net.cpp | 5 ----- src/net.h | 3 +-- 2 files changed, 1 insertion(+), 7 deletions(-) diff --git a/src/net.cpp b/src/net.cpp index e8739bddff..fd7c1189bf 100644 --- a/src/net.cpp +++ b/src/net.cpp @@ -4160,11 +4160,6 @@ std::vector CConnman::CopyNodeVector(std::function CConnman::CopyNodeVector() -{ - return CopyNodeVector(AllNodes); -} - void CConnman::ReleaseNodeVector(const std::vector& vecNodes) { for(size_t i = 0; i < vecNodes.size(); ++i) { diff --git a/src/net.h b/src/net.h index b80f9af9af..9f486a49ad 100644 --- a/src/net.h +++ b/src/net.h @@ -1173,8 +1173,7 @@ public: ForEachNodeThen(FullyConnectedOnly, pre, post); } - std::vector CopyNodeVector(std::function cond); - std::vector CopyNodeVector(); + std::vector CopyNodeVector(std::function cond = AllNodes); void ReleaseNodeVector(const std::vector& vecNodes); void RelayTransaction(const CTransaction& tx, const bool is_dstx);