mirror of
				https://git.wownero.com/wowlet/wowlet.git
				synced 2024-08-15 01:03:14 +00:00 
			
		
		
		
	Merge pull request 'Fix restore from seed functionality' (#40) from dsc/feather:fix-restore-seed into master
Reviewed-on: https://git.wownero.com/feather/feather/pulls/40
This commit is contained in:
		
						commit
						3668f0e27e
					
				
					 2 changed files with 7 additions and 1 deletions
				
			
		| 
						 | 
					@ -530,6 +530,11 @@ void AppContext::createWallet(FeatherSeed seed, const QString &path, const QStri
 | 
				
			||||||
        return;
 | 
					        return;
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    if(seed.mnemonicSeed.isEmpty()) {
 | 
				
			||||||
 | 
					        emit walletCreatedError("Mnemonic seed error. Failed to write wallet.");
 | 
				
			||||||
 | 
					        return;
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    this->currentWallet = seed.writeWallet(this->walletManager, this->networkType, path, password, this->kdfRounds);
 | 
					    this->currentWallet = seed.writeWallet(this->walletManager, this->networkType, path, password, this->kdfRounds);
 | 
				
			||||||
    if(this->currentWallet == nullptr) {
 | 
					    if(this->currentWallet == nullptr) {
 | 
				
			||||||
        emit walletCreatedError("Failed to write wallet");
 | 
					        emit walletCreatedError("Failed to write wallet");
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -53,7 +53,8 @@ WalletWizard::WalletWizard(AppContext *ctx, WalletWizard::Page startPage, QWidge
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
void WalletWizard::createWallet() {
 | 
					void WalletWizard::createWallet() {
 | 
				
			||||||
    auto mnemonicSeed = this->field("mnemonicSeed").toString();
 | 
					    auto mnemonicRestoredSeed = this->field("mnemonicRestoredSeed").toString();
 | 
				
			||||||
 | 
					    auto mnemonicSeed = mnemonicRestoredSeed.isEmpty() ? this->field("mnemonicSeed").toString() : mnemonicRestoredSeed;
 | 
				
			||||||
    const auto walletPath = this->field("walletPath").toString();
 | 
					    const auto walletPath = this->field("walletPath").toString();
 | 
				
			||||||
    const auto walletPasswd = this->field("walletPasswd").toString();
 | 
					    const auto walletPasswd = this->field("walletPasswd").toString();
 | 
				
			||||||
    auto restoreHeight = this->field("restoreHeight").toUInt();
 | 
					    auto restoreHeight = this->field("restoreHeight").toUInt();
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue