wallet2_api: recognize full size payment ids as valid

This commit is contained in:
moneromooo-monero 2016-10-16 13:54:53 +01:00
parent 34fcfcd7cc
commit b6b86ab347
No known key found for this signature in database
GPG Key ID: 686F07454D6CEFC3
1 changed files with 7 additions and 2 deletions

View File

@ -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()