From cc2b6fa1240ecd09584ce0b924df6d155cab1a5f Mon Sep 17 00:00:00 2001 From: Stixx Date: Thu, 2 Jan 2025 10:49:08 +0100 Subject: [PATCH] fix: zipUrls --- src/pages/sign/index.tsx | 1 + src/pages/verify/index.tsx | 9 +++++---- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/src/pages/sign/index.tsx b/src/pages/sign/index.tsx index d226243..f9427cd 100644 --- a/src/pages/sign/index.tsx +++ b/src/pages/sign/index.tsx @@ -167,6 +167,7 @@ export const SignPage = () => { createSignatureContent.markConfig, usersPubkey! ) + // TODO figure out why markConfig does not contain the usersPubkey when multiple signer const signedMarks = extractMarksFromSignedMeta(meta) const currentUserMarks = getCurrentUserMarks(metaMarks, signedMarks) const otherUserMarks = findOtherUserMarks(signedMarks, usersPubkey!) diff --git a/src/pages/verify/index.tsx b/src/pages/verify/index.tsx index 3831f97..0da3171 100644 --- a/src/pages/verify/index.tsx +++ b/src/pages/verify/index.tsx @@ -408,7 +408,7 @@ export const VerifyPage = () => { setLoadingSpinnerDesc('Fetching file from file server') for (let i = 0; i < zipUrls.length; i++) { - const zipUrl = '' + const zipUrl = zipUrls[i] const isLastZipUrl = i === zipUrls.length - 1 try { @@ -427,10 +427,11 @@ export const VerifyPage = () => { encryptedArrayBuffer, encryptionKey ).catch((err) => { + const error = err.message + ? `Decryption error: ${err.message}` + : 'An error occurred in decrypting file.' console.error('Error in decryption:>> ', err) - toast.error( - err.message || 'An error occurred in decrypting file.' - ) + toast.error(error) return null // Continue iteration for next zipUrl })