You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
Hi everybody, we use Trust wallet adapter on our application and we have a problem when we send transaction, Trust wallet try to serialize message from Transaction entity, but with "legacy" Transaction, there is no message property, only in VersionedTransaction. For me, this adapter isn't fully functional with Solana, have you a solution to fix this?
To Reproduce
Steps to reproduce the behavior:
Create function to create Transaction and send it with the wallet adapter:
// This function does not worksasyncfunctioncreateLegacyTransaction(from: PublicKey,to: PublicKey,amount: number){consttransaction=newTransaction()transaction.add(SystemProgram.transfer({fromPubkey: from,toPubkey: to,lamports: amount}))transaction.add(ComputeBudgetProgram.setComputeUnitPrice({microLamports: 100000}))const{ blockhash }=awaitconnection.getLatestBlockhash()transaction.recentBlockhash=blockhashtransaction.feePayer=fromreturntransaction;}// Function worksasyncfunctioncreateVersionedTransaction(from: PublicKey,to: PublicKey,amount: number){const{ blockhash }=awaitconnection.getLatestBlockhash()constmessageV0=newTransactionMessage({payerKey: from,recentBlockhash: blockhash,instructions: [SystemProgram.transfer({fromPubkey: from,toPubkey: to,lamports: amount}),ComputeBudgetProgram.setComputeUnitPrice({microLamports: 100000})],}).compileToV0Message();returnnewVersionedTransaction(messageV0)}
Expected behavior
This wallet should be compatible with Solana "legacy" Transaction.
The text was updated successfully, but these errors were encountered:
Describe the bug
Hi everybody, we use Trust wallet adapter on our application and we have a problem when we send transaction, Trust wallet try to serialize message from Transaction entity, but with "legacy" Transaction, there is no message property, only in VersionedTransaction. For me, this adapter isn't fully functional with Solana, have you a solution to fix this?
To Reproduce
Steps to reproduce the behavior:
Create function to create Transaction and send it with the wallet adapter:
Expected behavior
This wallet should be compatible with Solana "legacy" Transaction.
The text was updated successfully, but these errors were encountered: