broxus / everscale-inpage-provider

Web3-like interface to the Everscale blockchain.
https://broxus.github.io/everscale-inpage-provider/
GNU General Public License v3.0
30 stars 17 forks source link

Uncaught NekotonRpcError Error: sendMessage: TypeError: account.prepareMessage is not a function #12

Closed leductam2003 closed 1 year ago

leductam2003 commented 1 year ago
  const ever = new ProviderRpcClient({
    fallback: () =>
      EverscaleStandaloneClient.create({
        clock: new Clock(),
        connection: {
          id: 1000,
          group: 'venom_testnet',
          type: "jrpc",
          data: {
            endpoint: 'https://jrpc-testnet.venom.foundation/rpc'
          }
        },
        keystore: new SimpleKeystore({
          giverKey: Wallet,
          Wallet,
        }),
        accountsStorage: new SimpleAccountsStorage({
          entries: [giverAccount],
        }),
      }),
  });
  await ever.ensureInitialized();
  const VENOM_CONTRACT_MINT = new Address('0:b288234ed66c5d45250c01b5aa3a77f0b95050c4fb785bf62d05f580c9f7a341')
  const contract = new Contract(ever, VENOM_MINT_ABI ,VENOM_CONTRACT_MINT)
  const minter = await contract.methods.mintNftV2(info).send({
    from: new Address(address),
    amount : "1000000000",
  })
  console.log(minter)

account.prepareMessage i got this error when trying to call function, how can i fix it?