aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/wallet/api/wallet.cpp9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/wallet/api/wallet.cpp b/src/wallet/api/wallet.cpp
index 470f51281..747263b54 100644
--- a/src/wallet/api/wallet.cpp
+++ b/src/wallet/api/wallet.cpp
@@ -158,8 +158,13 @@ std::string Wallet::genPaymentId()
bool Wallet::paymentIdValid(const string &paiment_id)
{
- crypto::hash8 pid;
- return tools::wallet2::parse_short_payment_id(paiment_id, pid);
+ crypto::hash8 pid8;
+ if (tools::wallet2::parse_short_payment_id(paiment_id, pid8))
+ return true;
+ crypto::hash pid;
+ if (tools::wallet2::parse_long_payment_id(paiment_id, pid))
+ return true;
+ return false;
}
uint64_t Wallet::maximumAllowedAmount()