1
0
Fork 0
mirror of synced 2025-09-23 12:18:44 +00:00
This commit is contained in:
schaeff 2022-05-31 19:10:07 +02:00
parent 1e3342bc7f
commit 6a1f9c5020

View file

@ -47,7 +47,7 @@ impl CompilationResult {
pub fn snarkjs_program(&self) -> Option<js_sys::Uint8Array> {
self.snarkjs_program.as_ref().map(|p| {
let arr = js_sys::Uint8Array::new_with_length(p.len() as u32);
arr.copy_from(&p);
arr.copy_from(p);
arr
})
}
@ -58,7 +58,7 @@ impl ComputationResult {
pub fn snarkjs_witness(&self) -> Option<js_sys::Uint8Array> {
self.snarkjs_witness.as_ref().map(|w| {
let arr = js_sys::Uint8Array::new_with_length(w.len() as u32);
arr.copy_from(&w);
arr.copy_from(w);
arr
})
}