MCPcopy Create free account
hub / github.com/PerroEngine/Perro / decode_value

Function decode_value

perro_source/api_modules/perro_web/src/storage.rs:103–109  ·  view source on GitHub ↗
(data: &str)

Source from the content-addressed store, hash-verified

101
102#[cfg(target_arch = "wasm32")]
103fn decode_value(data: &str) -> io::Result<Vec<u8>> {
104 use base64::Engine as _;
105
106 base64::engine::general_purpose::STANDARD
107 .decode(data)
108 .map_err(|err| io::Error::new(io::ErrorKind::InvalidData, err))
109}
110
111#[cfg(target_arch = "wasm32")]
112fn js_err(err: wasm_bindgen::JsValue) -> io::Error {

Callers

nothing calls this directly

Calls 1

decodeMethod · 0.80

Tested by

no test coverage detected