1
1
Fork 0
mirror of https://github.com/oxen-io/lokinet synced 2023-12-14 06:53:00 +01:00

PR 2111 comments and fixes

This commit is contained in:
dan 2023-01-11 07:30:17 -08:00
parent 492e2f3af2
commit 3c72f9a549
3 changed files with 5 additions and 5 deletions

View file

@ -1135,7 +1135,7 @@ namespace llarp
"bind",
DefaultRPCBind,
MultiValue,
[=, first = true](std::string arg) mutable {
[this, first = true](std::string arg) mutable {
if (first)
{
m_rpcBindAddresses.clear();

View file

@ -25,13 +25,13 @@ namespace llarp::rpc
RpcServer::RpcServer(LMQ_ptr lmq, AbstractRouter* r)
: m_LMQ{std::move(lmq)}, m_Router{r}, log_subs{*m_LMQ, llarp::logRingBuffer}
{
for (auto addr : r->GetConfig()->api.m_rpcBindAddresses)
for (const auto& addr : r->GetConfig()->api.m_rpcBindAddresses)
{
m_LMQ->listen_plain(addr.zmq_address());
LogInfo("Bound RPC server to ", addr.full_address());
}
this->AddRPCCats();
this->AddRPCCategories();
}
/// maybe parse json from message paramter at index
@ -150,7 +150,7 @@ namespace llarp::rpc
}
void
RpcServer::AddRPCCats()
RpcServer::AddRPCCategories()
{
m_LMQ->add_category("llarp", oxenmq::AuthLevel::none)
.add_request_command("logs", [this](oxenmq::Message& msg) { HandleLogsSubRequest(msg); })

View file

@ -21,7 +21,7 @@ namespace llarp::rpc
~RpcServer() = default;
void
AddRPCCats();
AddRPCCategories();
private:
void