mirror of
https://github.com/ElementsProject/elements.git
synced 2026-08-17 13:07:54 +02:00
Use std::string_view throughout util strencodings/string
This commit is contained in:
parent
8ffbd1412d
commit
e7d2fbda63
9 changed files with 69 additions and 56 deletions
|
|
@ -240,7 +240,7 @@ static void MutateTxRBFOptIn(CMutableTransaction& tx, const std::string& strInId
|
|||
template <typename T>
|
||||
static T TrimAndParse(const std::string& int_str, const std::string& err)
|
||||
{
|
||||
const auto parsed{ToIntegral<T>(TrimString(int_str))};
|
||||
const auto parsed{ToIntegral<T>(TrimStringView(int_str))};
|
||||
if (!parsed.has_value()) {
|
||||
throw std::runtime_error(err + " '" + int_str + "'");
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue