use std::string_view instead const std::string&

This commit is contained in:
orignal 2025-01-12 12:23:26 -05:00
parent efd8e6e65b
commit 634ceceb1c
8 changed files with 58 additions and 52 deletions

View file

@ -921,7 +921,7 @@ namespace client
case 1: // address
{
auto name = ExtractString (buf + 11, len - 11);
auto addr = i2p::client::context.GetAddressBook ().GetAddress (std::string (name)); // TODO: GetAddress should take string_view
auto addr = i2p::client::context.GetAddressBook ().GetAddress (name);
if (!addr || !addr->IsIdentHash ())
{
// TODO: handle blinded addresses