spread Uint8Arrays
This commit is contained in:
parent
2551462003
commit
358311e8ac
@ -57,13 +57,7 @@ export const encryptArrayBuffer = async (
|
|||||||
|
|
||||||
const prefix = new TextEncoder().encode("Salted__");
|
const prefix = new TextEncoder().encode("Salted__");
|
||||||
|
|
||||||
const res = new Uint8Array(
|
const res = new Uint8Array([...prefix, ...salt, ...new Uint8Array(enc)]);
|
||||||
[
|
|
||||||
...prefix,
|
|
||||||
...salt,
|
|
||||||
...new Uint8Array(enc)
|
|
||||||
]
|
|
||||||
);
|
|
||||||
|
|
||||||
return bufferToArrayBuffer(res);
|
return bufferToArrayBuffer(res);
|
||||||
};
|
};
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user