From bc145da89799118260d04b5c0c909cb4b4aa3773 Mon Sep 17 00:00:00 2001 From: AuroraHuang22 Date: Fri, 17 Nov 2023 12:29:52 +0800 Subject: [PATCH] =?UTF-8?q?=F0=9F=9A=91=20Fix=20reading=20metadata=20undef?= =?UTF-8?q?ined?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- components/IscnUploadForm.vue | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/components/IscnUploadForm.vue b/components/IscnUploadForm.vue index 2f7a831f..16e298ab 100644 --- a/components/IscnUploadForm.vue +++ b/components/IscnUploadForm.vue @@ -709,7 +709,9 @@ export default class UploadForm extends Vue { this.sentArweaveTransactionInfo.set(records.ipfsHash, { ...uploadedData, arweaveId }); if (tempRecord.fileName.includes('cover.jpeg')) { const metadata = this.epubMetadataList.find((file: any) => file.ipfsHash === records.ipfsHash) - metadata.thumbnailUrl = arweaveId + if (metadata && metadata.thumbnailUrl) { + metadata.thumbnailUrl = arweaveId + } } this.$emit('arweaveUploaded', { arweaveId }) this.isOpenSignDialog = false