mirror of
https://github.com/MaSzyna-EU07/maszyna.git
synced 2026-10-18 02:09:18 +02:00
refactor(sonar): use try_emplace for map insertion (cpp:S6030)
This commit is contained in:
@@ -151,7 +151,7 @@ void network::server::handle_message(std::shared_ptr<connection> conn, const mes
|
||||
const auto& cmd = dynamic_cast<const request_command&>(msg);
|
||||
|
||||
for (auto const &kv : cmd.commands)
|
||||
client_commands_queue.emplace(kv);
|
||||
client_commands_queue.try_emplace(kv.first, kv.second);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user