From 6a342576d6403384745609e9ff2b52446a28e395 Mon Sep 17 00:00:00 2001 From: Vatsal Sanjay Date: Fri, 17 Jul 2026 13:18:58 +0100 Subject: [PATCH] Guard missing clipboard helper Avoid throwing before the contact card's existing error handling when the shared utility object is present but copyToClipboard is unavailable. --- assets/js/contact-card.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/assets/js/contact-card.js b/assets/js/contact-card.js index 03d3583..d0bf4a2 100644 --- a/assets/js/contact-card.js +++ b/assets/js/contact-card.js @@ -18,7 +18,7 @@ }; const copyText = async (button, text) => { - const copied = await window.Utils?.copyToClipboard(button, text); + const copied = await window.Utils?.copyToClipboard?.(button, text); if (!copied) throw new Error("Copy command unavailable"); };