Skip to content

Commit

Permalink
construct constant erc20 contract instance (#218)
Browse files Browse the repository at this point in the history
  • Loading branch information
bh2smith authored Mar 27, 2023
1 parent cfca9e0 commit ed29d41
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/models/transfer.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@
from src.models.vouch import Vouch
from src.utils.print_store import Category, PrintStore

ERC20_CONTRACT = erc20()


@dataclass
class CSVTransfer:
Expand Down Expand Up @@ -197,7 +199,7 @@ def as_multisend_tx(self) -> MultiSendTx:
operation=MultiSendOperation.CALL,
to=str(self.token.address),
value=0,
data=erc20().encodeABI(
data=ERC20_CONTRACT.encodeABI(
fn_name="transfer", args=[receiver, self.amount_wei]
),
)
Expand Down

0 comments on commit ed29d41

Please sign in to comment.