From 3e02b3924a62c30ac256a22e9e42661c55e3510b Mon Sep 17 00:00:00 2001 From: Jose Olarte III Date: Wed, 28 May 2025 19:08:15 +0800 Subject: [PATCH] Look for DID in .iss field instead of .own.did --- src/views/ContactQRScanFullView.vue | 6 +++--- src/views/ContactQRScanShowView.vue | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/views/ContactQRScanFullView.vue b/src/views/ContactQRScanFullView.vue index 02e228a5..2f389caf 100644 --- a/src/views/ContactQRScanFullView.vue +++ b/src/views/ContactQRScanFullView.vue @@ -357,8 +357,8 @@ export default class ContactQRScan extends Vue { } const contactInfo = decodedJwt.payload.own; - if (!contactInfo.did) { - logger.warn("Invalid contact info - missing DID"); + if (!decodedJwt.payload.iss) { + logger.warn("Invalid JWT payload - missing 'iss' field"); this.$notify({ group: "alert", type: "danger", @@ -370,7 +370,7 @@ export default class ContactQRScan extends Vue { // Create contact object const contact = { - did: contactInfo.did, + did: decodedJwt.payload.iss, name: contactInfo.name || "", email: contactInfo.email || "", phone: contactInfo.phone || "", diff --git a/src/views/ContactQRScanShowView.vue b/src/views/ContactQRScanShowView.vue index 35974cab..61101881 100644 --- a/src/views/ContactQRScanShowView.vue +++ b/src/views/ContactQRScanShowView.vue @@ -483,8 +483,8 @@ export default class ContactQRScanShow extends Vue { } const contactInfo = decodedJwt.payload.own; - if (!contactInfo.did) { - logger.warn("Invalid contact info - missing DID"); + if (!decodedJwt.payload.iss) { + logger.warn("Invalid JWT payload - missing 'iss' field"); this.$notify({ group: "alert", type: "danger", @@ -496,7 +496,7 @@ export default class ContactQRScanShow extends Vue { // Create contact object const contact = { - did: contactInfo.did, + did: decodedJwt.payload.iss, name: contactInfo.name || "", email: contactInfo.email || "", phone: contactInfo.phone || "",