mirror of
https://git.wownero.com/wownero/wownero.git
synced 2024-08-15 01:03:23 +00:00
simplewallet: add multisig to wallet type in wallet_info output
This commit is contained in:
parent
265290388b
commit
7f4c220b70
1 changed files with 11 additions and 1 deletions
|
@ -5987,10 +5987,20 @@ bool simple_wallet::status(const std::vector<std::string> &args)
|
||||||
//----------------------------------------------------------------------------------------------------
|
//----------------------------------------------------------------------------------------------------
|
||||||
bool simple_wallet::wallet_info(const std::vector<std::string> &args)
|
bool simple_wallet::wallet_info(const std::vector<std::string> &args)
|
||||||
{
|
{
|
||||||
|
bool ready;
|
||||||
|
uint32_t threshold, total;
|
||||||
|
|
||||||
message_writer() << tr("Filename: ") << m_wallet->get_wallet_file();
|
message_writer() << tr("Filename: ") << m_wallet->get_wallet_file();
|
||||||
message_writer() << tr("Description: ") << m_wallet->get_description();
|
message_writer() << tr("Description: ") << m_wallet->get_description();
|
||||||
message_writer() << tr("Address: ") << m_wallet->get_account().get_public_address_str(m_wallet->testnet());
|
message_writer() << tr("Address: ") << m_wallet->get_account().get_public_address_str(m_wallet->testnet());
|
||||||
message_writer() << tr("Watch only: ") << (m_wallet->watch_only() ? tr("Yes") : tr("No"));
|
std::string type;
|
||||||
|
if (m_wallet->watch_only())
|
||||||
|
type = tr("Watch only");
|
||||||
|
else if (m_wallet->multisig(&ready, &threshold, &total))
|
||||||
|
type = (boost::format(tr("%u/%u multisig%s")) % threshold % total % (ready ? "" : " (not yet finalized)")).str();
|
||||||
|
else
|
||||||
|
type = tr("Normal");
|
||||||
|
message_writer() << tr("Type: ") << type;
|
||||||
message_writer() << tr("Testnet: ") << (m_wallet->testnet() ? tr("Yes") : tr("No"));
|
message_writer() << tr("Testnet: ") << (m_wallet->testnet() ? tr("Yes") : tr("No"));
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue