forked from jsnbuchanan/crowd-funder-for-time-pwa
Fix: restore newer clipboard service call
This commit is contained in:
@@ -183,7 +183,6 @@ import {
|
|||||||
NOTIFY_QR_PROCESSING_ERROR,
|
NOTIFY_QR_PROCESSING_ERROR,
|
||||||
createQRContactAddedMessage,
|
createQRContactAddedMessage,
|
||||||
createQRRegistrationSuccessMessage,
|
createQRRegistrationSuccessMessage,
|
||||||
QR_TIMEOUT_SHORT,
|
|
||||||
|
|
||||||
QR_TIMEOUT_STANDARD,
|
QR_TIMEOUT_STANDARD,
|
||||||
QR_TIMEOUT_LONG,
|
QR_TIMEOUT_LONG,
|
||||||
@@ -623,18 +622,15 @@ export default class ContactQRScanShow extends Vue {
|
|||||||
);
|
);
|
||||||
|
|
||||||
// Copy the URL to clipboard
|
// Copy the URL to clipboard
|
||||||
useClipboard()
|
const { copyToClipboard } = await import("../services/ClipboardService");
|
||||||
.copy(jwtUrl)
|
await copyToClipboard(jwtUrl);
|
||||||
.then(() => {
|
this.notify.toast(
|
||||||
this.notify.toast(
|
NOTIFY_QR_URL_COPIED.title,
|
||||||
"Copied",
|
NOTIFY_QR_URL_COPIED.message,
|
||||||
NOTIFY_QR_URL_COPIED.message,
|
);
|
||||||
QR_TIMEOUT_MEDIUM,
|
|
||||||
);
|
|
||||||
});
|
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
logger.error("Failed to generate contact URL:", error);
|
this.$logAndConsole(`Error copying URL to clipboard: ${error}`, true);
|
||||||
this.notify.error("Failed to generate contact URL. Please try again.");
|
this.notify.error("Failed to copy URL to clipboard.");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user