Skip to content

Commit

Permalink
[GUI] Cold staking, alert user if the owner address is not from the w…
Browse files Browse the repository at this point in the history
…allet.
  • Loading branch information
furszy committed Nov 20, 2019
1 parent 31e9f0f commit 0b8f1b5
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions src/qt/pivx/coldstakingwidget.cpp
Expand Up @@ -422,6 +422,16 @@ void ColdStakingWidget::onSendClicked(){

if (!isOwnerAddressFromThisWallet) {
isOwnerAddressFromThisWallet = walletModel->isMine(inputOwner);

// Warn the user if the owner address is not from this wallet
if (!isOwnerAddressFromThisWallet &&
!ask(tr("ALERT!"),
tr("The owner address is not from this wallet!\n\n"
"If you continue and you don't have the address's ownership in\nanother device (like a hardware wallet or a piece of paper)\nthen you will NOT be able to spend back your coins!\n\n"
"Are you absolutely sure?"))
) {
return;
}
}

// Don't try to delegate the balance if both addresses are from this wallet
Expand Down

0 comments on commit 0b8f1b5

Please sign in to comment.