Skip to content

Commit

Permalink
fix: add try add tx type byte
Browse files Browse the repository at this point in the history
  • Loading branch information
quertc committed Aug 22, 2024
1 parent 7551b2d commit cfde2e5
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/signers/common.rs
Original file line number Diff line number Diff line change
Expand Up @@ -27,13 +27,15 @@ pub async fn handle_eth_sign_transaction(
let tx_envelope = tx_request.build(&signer).await?;
println!("tx_envelope: {:?}", tx_envelope.tx_type());
println!("tx_envelope: {:?}", tx_envelope);
tx_envelope.signature_hash();

let mut encoded_tx = vec![];
encoded_tx.push(tx_envelope.tx_type() as u8);
tx_envelope.encode(&mut encoded_tx);
println!("encoded_tx: {:?}", encoded_tx);
let rlp_hex = hex::encode_prefixed(encoded_tx);

println!("rlp_hex: {:?}", rlp_hex);;
println!("rlp_hex: {:?}", rlp_hex);

Ok(JsonRpcReply {
id: payload.id,
Expand Down

0 comments on commit cfde2e5

Please sign in to comment.