pub fn decode_hex(hex: &str) -> Result<Vec<u8>>
Decode hex string (with or without 0x prefix) to bytes.
Returns an error if the hex string is invalid.