Apply the encoding that Tendermint does to the bytes inside [`DeliverTx`].
(data: &[u8])
| 22 | |
| 23 | /// Apply the encoding that Tendermint does to the bytes inside [`DeliverTx`]. |
| 24 | pub fn encode_data(data: &[u8]) -> Bytes { |
| 25 | let b64 = base64::engine::general_purpose::STANDARD.encode(data); |
| 26 | let bz = b64.as_bytes(); |
| 27 | Bytes::copy_from_slice(bz) |
| 28 | } |
| 29 | |
| 30 | /// Parse what Tendermint returns in the `data` field of [`DeliverTx`] as raw bytes. |
| 31 | /// |
no test coverage detected