From 55e08b49339d5b0bf5d96089574258a0d7c320c5 Mon Sep 17 00:00:00 2001 From: Zaptoss Date: Tue, 17 Sep 2024 18:32:58 +0300 Subject: [PATCH] Fix mint --- internal/config/rarimarket.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/internal/config/rarimarket.go b/internal/config/rarimarket.go index e6b6321..57a5a52 100644 --- a/internal/config/rarimarket.go +++ b/internal/config/rarimarket.go @@ -41,6 +41,7 @@ type rarimarketConfig struct { type RarimarketConfig struct { RPC *ethclient.Client AccountFactory common.Address + PointTokens common.Address ChainID *big.Int PointPrice int64 @@ -81,6 +82,7 @@ func (c *rarimarketConfig) RarimarketConfig() *RarimarketConfig { return &RarimarketConfig{ RPC: cfg.RPC, AccountFactory: cfg.AccountFactory, + PointTokens: cfg.PointTokens, ChainID: chainID, PointPrice: cfg.PointPrice, @@ -156,7 +158,7 @@ func (r *RarimarketConfig) Mint(ctx context.Context, account common.Address, amo return fmt.Errorf("failed to get keyed transactor: %w", err) } - pointTokensInstance, err := pointTokens.NewPoints(r.AccountFactory, r.RPC) + pointTokensInstance, err := pointTokens.NewPoints(r.PointTokens, r.RPC) if err != nil { return fmt.Errorf("failed to get account factory: %w", err) }