Skip to content

Commit

Permalink
remove checks as amount is now required to pass
Browse files Browse the repository at this point in the history
  • Loading branch information
borispoehland committed Sep 17, 2024
1 parent 6df4e22 commit 7b9de68
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions src/interactions/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -712,9 +712,6 @@ export class SCInteraction {
payment: Payment,
sender: WithSenderAndNonce
): IPlainTransactionObject {
if (!payment.amount) {
throw new Error('Payment amount is required')
}
const isEgld = payment.collection == 'EGLD'
const tx = this.factory.createTransactionForExecute({
sender: new Address(sender.address),
Expand Down Expand Up @@ -762,9 +759,6 @@ export class SCInteraction {
interaction.withNonce(sender.nonce)
}
interaction.withSender(new Address(sender.address))
if (!payment.amount) {
throw new Error('Payment amount is required')
}
if (payment.collection == 'EGLD') {
interaction.withValue(payment.amount)
} else {
Expand Down

0 comments on commit 7b9de68

Please sign in to comment.