mirror of
https://github.com/kmc7468/arkvault.git
synced 2025-12-16 15:08:46 +00:00
사소한 리팩토링 2
This commit is contained in:
@@ -114,7 +114,7 @@ export const uploadFile = async (
|
||||
|
||||
try {
|
||||
const hashStream = createHash("sha256");
|
||||
const [_, hash] = await Promise.all([
|
||||
const [, hash] = await Promise.all([
|
||||
pipeline(
|
||||
encContentStream,
|
||||
async function* (source) {
|
||||
@@ -127,7 +127,7 @@ export const uploadFile = async (
|
||||
),
|
||||
encContentHash,
|
||||
]);
|
||||
if (hashStream.digest("base64") != hash) {
|
||||
if (hashStream.digest("base64") !== hash) {
|
||||
throw new Error("Invalid checksum");
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user