Skip to content

Commit

Permalink
Return void in add method
Browse files Browse the repository at this point in the history
  • Loading branch information
Jouzo committed Feb 4, 2022
1 parent 024d040 commit 4e0c7a6
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/rpc/stats.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ RPCStats RPCStats::fromJSON(UniValue json) {
return stats;
}

bool CRPCStats::add(const std::string& name, const int64_t latency, const int64_t payload)
void CRPCStats::add(const std::string& name, const int64_t latency, const int64_t payload)
{
auto stats = CRPCStats::get(name);
if (stats) {
Expand Down
2 changes: 1 addition & 1 deletion src/rpc/stats.h
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ class CRPCStats
private:
std::map<std::string, RPCStats> map;
public:
bool add(const std::string& name, const int64_t latency, const int64_t payload);
void add(const std::string& name, const int64_t latency, const int64_t payload);

std::optional<RPCStats> get(const std::string& name) {
auto it = map.find(name);
Expand Down

0 comments on commit 4e0c7a6

Please sign in to comment.