MCPcopy Create free account
hub / github.com/Dstack-TEE/dstack / hex_decode

Function hex_decode

dstack-util/src/main.rs:221–223  ·  view source on GitHub ↗
(hex_str: &str)

Source from the content-addressed store, hash-verified

219}
220
221fn hex_decode(hex_str: &str) -> Result<Vec<u8>> {
222 hex::decode(hex_str.trim_start_matches("0x")).context("Invalid hex string")
223}
224
225fn cmd_extend(extend_args: ExtendArgs) -> Result<()> {
226 let payload = hex_decode(&extend_args.payload).context("Failed to decode payload")?;

Callers 1

cmd_extendFunction · 0.85

Calls 1

decodeFunction · 0.85

Tested by

no test coverage detected