diff options
author | Riccardo Spagni <ric@spagni.net> | 2018-03-05 19:12:24 +0200 |
---|---|---|
committer | Riccardo Spagni <ric@spagni.net> | 2018-03-05 19:12:24 +0200 |
commit | 5b25cbb5a743d29dcc8528a1d7fb2e0a8bb5cc29 (patch) | |
tree | 93dfd5bf3a4bab13f195c8419319be3049afd9e1 /src/wallet | |
parent | Merge pull request #3308 (diff) | |
parent | wallet api: when restoring from EnglishOld, set language to English (diff) | |
download | monero-5b25cbb5a743d29dcc8528a1d7fb2e0a8bb5cc29.tar.xz |
Merge pull request #3314
71bff546 wallet api: when restoring from EnglishOld, set language to English (stoffu)
Diffstat (limited to 'src/wallet')
-rw-r--r-- | src/wallet/api/wallet.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/wallet/api/wallet.cpp b/src/wallet/api/wallet.cpp index 0ed6601af..335fbf903 100644 --- a/src/wallet/api/wallet.cpp +++ b/src/wallet/api/wallet.cpp @@ -40,6 +40,7 @@ #include "common/util.h" #include "mnemonics/electrum-words.h" +#include "mnemonics/english.h" #include <boost/format.hpp> #include <sstream> #include <unordered_map> @@ -603,6 +604,9 @@ bool WalletImpl::recover(const std::string &path, const std::string &password, c return false; } + if (old_language == crypto::ElectrumWords::old_language_name) + old_language = Language::English().get_language_name(); + try { m_wallet->set_seed_language(old_language); m_wallet->generate(path, password, recovery_key, true, false); |