Function enigma_tools_u::web3_utils::w3utils::trunace_bytecode[][src]

pub fn trunace_bytecode(bytecode: &String) -> Result<Vec<u8>, Error>

private:: truncate the bytecode from solidity json this method does 2 things:

  1. web3 requires byte array of the hex byte code from_hex
  2. serde_json reads the bytecode as string with '"0x..."' so 4 chars needs to be removed.