diff options
author | James O'Beirne <james.obeirne@gmail.com> | 2018-04-10 11:50:10 -0400 |
---|---|---|
committer | James O'Beirne <james.obeirne@gmail.com> | 2018-04-25 13:08:53 -0400 |
commit | c5b277033a72650c221084ec0f1326623a810fd0 (patch) | |
tree | 4ea793666e91c081e738dcab2cdfe2078c2e60c3 /src/qt/addresstablemodel.cpp | |
parent | a785bc3667d3c11a014da77436a23b1b865458a4 (diff) |
Add purpose arg to Wallet::getAddress
Also make all arguments to getAddress required and document args at call sites.
Diffstat (limited to 'src/qt/addresstablemodel.cpp')
-rw-r--r-- | src/qt/addresstablemodel.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/qt/addresstablemodel.cpp b/src/qt/addresstablemodel.cpp index 1e3acd75c0..d85a13cd5b 100644 --- a/src/qt/addresstablemodel.cpp +++ b/src/qt/addresstablemodel.cpp @@ -266,7 +266,8 @@ bool AddressTableModel::setData(const QModelIndex &index, const QVariant &value, } // Check for duplicate addresses to prevent accidental deletion of addresses, if you try // to paste an existing address over another address (with a different label) - if (walletModel->wallet().getAddress(newAddress)) + if (walletModel->wallet().getAddress( + newAddress, /* name= */ nullptr, /* is_mine= */ nullptr, /* purpose= */ nullptr)) { editStatus = DUPLICATE_ADDRESS; return false; @@ -351,7 +352,8 @@ QString AddressTableModel::addRow(const QString &type, const QString &label, con } // Check for duplicate addresses { - if(walletModel->wallet().getAddress(DecodeDestination(strAddress))) + if (walletModel->wallet().getAddress( + DecodeDestination(strAddress), /* name= */ nullptr, /* is_mine= */ nullptr, /* purpose= */ nullptr)) { editStatus = DUPLICATE_ADDRESS; return QString(); |