From dee448fe5190a05fdb16e98abd535db3081e737f Mon Sep 17 00:00:00 2001 From: sowle Date: Fri, 8 May 2020 22:59:51 +0300 Subject: [PATCH] fixed extra_alias_info handling in tx_extra_handler and rpc_tx_payload_handler (+payer and receiver) --- src/currency_core/currency_format_utils.cpp | 22 ++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) diff --git a/src/currency_core/currency_format_utils.cpp b/src/currency_core/currency_format_utils.cpp index b3247fce..feae4e80 100644 --- a/src/currency_core/currency_format_utils.cpp +++ b/src/currency_core/currency_format_utils.cpp @@ -421,13 +421,16 @@ namespace currency rei.m_attachment_info = ai; return true; } - bool operator()(const extra_alias_entry& ae) const { ENSURE_ONETIME(was_alias, "alias"); rei.m_alias = ae; return true; } + bool operator()(const extra_alias_entry_old& ae) const + { + return operator()(static_cast(ae)); + } bool operator()(const extra_user_data& ud) const { ENSURE_ONETIME(was_userdata, "userdata"); @@ -2181,6 +2184,10 @@ namespace currency return true; } + bool operator()(const extra_alias_entry_old& ee) + { + return operator()(static_cast(ee)); + } bool operator()(const extra_user_data& ee) { tv.type = "user_data"; @@ -2214,7 +2221,13 @@ namespace currency return true; } + bool operator()(const tx_payer_old&) + { + tv.type = "payer_old"; + tv.short_view = "(encrypted)"; + return true; + } bool operator()(const tx_receiver& ee) { //const tx_payer& ee = boost::get(extra); @@ -2223,6 +2236,13 @@ namespace currency return true; } + bool operator()(const tx_receiver_old& ee) + { + tv.type = "receiver_old"; + tv.short_view = "(encrypted)"; + + return true; + } bool operator()(const tx_derivation_hint& ee) { tv.type = "derivation_hint";