1
transaction.add(
    SystemProgram.transfer({
      fromPubkey: publicKey,
      toPubkey: new PublicKey(
        "wallet here"
      ),
      lamports: 0.0069 * 10 ** 9,
    })
);

const {
    context: { slot: minContextSlot },
  } = await connection.getLatestBlockhashAndContext();

    signature = await sendTransaction(transaction, connection, {
      minContextSlot,
    });

I also have a createAssociatedTokenAddress instruction added before that SOL transfer. But the thing is, this is working locally perfectly fine. When deploying my nextjs app to aws amplify, this stops working. Tried to make SWCMinify to false, nothing changed (as this was something I encountered previously and it worked)

Getting the following error:

enter image description here

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.