check that recipient user has activated account in send coins

This commit is contained in:
Moriz Wahl 2022-04-05 15:12:36 +02:00
parent c54ec6cf6a
commit 69dae586d8

View File

@ -263,6 +263,9 @@ export class TransactionResolver {
if (recipientUser.deletedAt) {
throw new Error('The recipient account was deleted')
}
if (!recipientUser.emailChecked) {
throw new Error('The recipient account is not activated')
}
if (!isHexPublicKey(recipientUser.pubKey.toString('hex'))) {
throw new Error('invalid recipient public key')
}