aboutsummaryrefslogtreecommitdiff
path: root/src/simplewallet/simplewallet.cpp
diff options
context:
space:
mode:
authorluigi1111 <luigi1111w@gmail.com>2019-08-21 15:17:26 -0500
committerluigi1111 <luigi1111w@gmail.com>2019-08-21 15:17:26 -0500
commitde30131abdfdbd4b7dc040dd1d276067e6c46dda (patch)
treeb18d392ce127f805e20bbcb15887f1c721c1443d /src/simplewallet/simplewallet.cpp
parentMerge pull request #5742 (diff)
parentsimplewallet: add restore_height command (diff)
downloadmonero-de30131abdfdbd4b7dc040dd1d276067e6c46dda.tar.xz
Merge pull request #5743
65f29a8 simplewallet: add restore_height command (tobtoht)
Diffstat (limited to 'src/simplewallet/simplewallet.cpp')
-rw-r--r--src/simplewallet/simplewallet.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/simplewallet/simplewallet.cpp b/src/simplewallet/simplewallet.cpp
index 3d99efc99..c107d0394 100644
--- a/src/simplewallet/simplewallet.cpp
+++ b/src/simplewallet/simplewallet.cpp
@@ -803,6 +803,12 @@ bool simple_wallet::encrypted_seed(const std::vector<std::string> &args/* = std:
return print_seed(true);
}
+bool simple_wallet::restore_height(const std::vector<std::string> &args/* = std::vector<std::string>()*/)
+{
+ success_msg_writer() << m_wallet->get_refresh_from_block_height();
+ return true;
+}
+
bool simple_wallet::seed_set_language(const std::vector<std::string> &args/* = std::vector<std::string>()*/)
{
if (m_wallet->key_on_device())
@@ -2845,6 +2851,9 @@ simple_wallet::simple_wallet()
m_cmd_binder.set_handler("seed",
boost::bind(&simple_wallet::seed, this, _1),
tr("Display the Electrum-style mnemonic seed"));
+ m_cmd_binder.set_handler("restore_height",
+ boost::bind(&simple_wallet::restore_height, this, _1),
+ tr("Display the restore height"));
m_cmd_binder.set_handler("set",
boost::bind(&simple_wallet::set_variable, this, _1),
tr(USAGE_SET_VARIABLE),