diff --git a/src/simplewallet/simplewallet.cpp b/src/simplewallet/simplewallet.cpp index 56fc9dd3..beaa7612 100644 --- a/src/simplewallet/simplewallet.cpp +++ b/src/simplewallet/simplewallet.cpp @@ -2116,10 +2116,7 @@ bool simple_wallet::generate_ionic_swap_proposal(const std::vector fail_msg_writer() << "Failed to load json file with asset specification: " << args[0]; return true; } -// if (proposal_info.expiration_time == 0) -// { -// proposal_info.expiration_time = m_wallet->get_core_runtime_config().get_core_time() + 10 * 60; -// } + currency::account_public_address destination_addr = AUTO_VAL_INIT(destination_addr); currency::payment_id_t integrated_payment_id; if (!m_wallet->get_transfer_address(args[1], destination_addr, integrated_payment_id)) diff --git a/src/wallet/wallet2.cpp b/src/wallet/wallet2.cpp index 182127fc..9973feb6 100644 --- a/src/wallet/wallet2.cpp +++ b/src/wallet/wallet2.cpp @@ -5381,10 +5381,6 @@ bool wallet2::build_ionic_swap_template(const wallet_public::ionic_swap_proposal ctp.mark_tx_as_complete = false; ctp.crypt_address = destination_addr; - //etc_tx_details_expiration_time t = AUTO_VAL_INIT(t); - //t.v = 0;//proposal_detais.expiration_time; - //ctp.extra.push_back(t); - ctp.dsts.resize(proposal_detais.to_bob.size() + proposal_detais.to_alice.size()); size_t i = 0; // Here is an proposed for exchange funds @@ -5416,7 +5412,6 @@ bool wallet2::build_ionic_swap_template(const wallet_public::ionic_swap_proposal selected_transfers = ftp.selected_transfers; currency::finalized_tx finalize_result = AUTO_VAL_INIT(finalize_result); finalize_transaction(ftp, finalize_result, false); - //add_transfers_to_expiration_list(selected_transfers, for_expiration_list, this->get_core_runtime_config().get_core_time() + proposal_detais.expiration_time, currency::null_hash); //wrap it all proposal.tx_template = finalize_result.tx; @@ -5572,13 +5567,6 @@ bool wallet2::get_ionic_swap_proposal_info(const wallet_public::ionic_swap_propo proposal_info.to_alice.push_back(view::asset_funds{ a.first, a.second - amounts_provided_by_a[a.first] }); } - //etc_tx_details_expiration_time t = AUTO_VAL_INIT(t); - //if (!get_type_in_variant_container(tx.extra, t)) - //{ - // return false; - //} - - //proposal_info.expiration_time = t.v; return true; } diff --git a/tests/core_tests/ionic_swap_tests.cpp b/tests/core_tests/ionic_swap_tests.cpp index 5c5f9e19..68c7d855 100644 --- a/tests/core_tests/ionic_swap_tests.cpp +++ b/tests/core_tests/ionic_swap_tests.cpp @@ -1,4 +1,4 @@ -// Copyright (c) 2014-2022 Zano Project +// Copyright (c) 2014-2023 Zano Project // Copyright (c) 2014-2018 The Louisdor Project // Distributed under the MIT/X11 software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. @@ -140,7 +140,6 @@ bool ionic_swap_basic_test::c1(currency::core& c, size_t ev_index, const std::ve { //alice_wlt want to trade with bob_wlt, to exchange 10.0 TCT to 1.0 ZANO view::ionic_swap_proposal_info proposal_details = AUTO_VAL_INIT(proposal_details); - proposal_details.expiration_time = alice_wlt->get_core_runtime_config().get_core_time() + 10 * 60; proposal_details.fee_paid_by_a = TESTS_DEFAULT_FEE; proposal_details.mixins = 10; proposal_details.to_bob.push_back(view::asset_funds{ asset_id , assets_to_exchange }); @@ -198,7 +197,6 @@ bool ionic_swap_basic_test::c1(currency::core& c, size_t ev_index, const std::ve { //now alice_wlt want to trade with bob_wlt, to send 1.0 ZANO and get 10.0 TCT in exchange view::ionic_swap_proposal_info proposal_details = AUTO_VAL_INIT(proposal_details); - proposal_details.expiration_time = alice_wlt->get_core_runtime_config().get_core_time() + 10 * 60; proposal_details.fee_paid_by_a = TESTS_DEFAULT_FEE; proposal_details.mixins = 10; proposal_details.to_bob.push_back(view::asset_funds{ currency::native_coin_asset_id , native_tokens_to_exchange }); diff --git a/tests/core_tests/ionic_swap_tests.h b/tests/core_tests/ionic_swap_tests.h index 576c796c..d5a9978f 100644 --- a/tests/core_tests/ionic_swap_tests.h +++ b/tests/core_tests/ionic_swap_tests.h @@ -1,4 +1,4 @@ -// Copyright (c) 2014-2022 Zano Project +// Copyright (c) 2014-2023 Zano Project // Distributed under the MIT/X11 software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #pragma once