summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ext/bg/js/api.js8
-rw-r--r--ext/bg/js/backend.js8
2 files changed, 8 insertions, 8 deletions
diff --git a/ext/bg/js/api.js b/ext/bg/js/api.js
index 49a6c14f..095734fb 100644
--- a/ext/bg/js/api.js
+++ b/ext/bg/js/api.js
@@ -93,10 +93,6 @@ function apiGetEnvironmentInfo() {
return utilBackend()._onApiGetEnvironmentInfo();
}
-async function apiClipboardGet() {
- const clipboardPasteTarget = utilBackend().clipboardPasteTarget;
- clipboardPasteTarget.innerText = '';
- clipboardPasteTarget.focus();
- document.execCommand('paste');
- return clipboardPasteTarget.innerText;
+function apiClipboardGet() {
+ return utilBackend()._onApiClipboardGet();
}
diff --git a/ext/bg/js/backend.js b/ext/bg/js/backend.js
index 62c077a2..877161c7 100644
--- a/ext/bg/js/backend.js
+++ b/ext/bg/js/backend.js
@@ -475,8 +475,12 @@ class Backend {
};
}
- _onApiClipboardGet() {
- return apiClipboardGet();
+ async _onApiClipboardGet() {
+ const clipboardPasteTarget = this.clipboardPasteTarget;
+ clipboardPasteTarget.innerText = '';
+ clipboardPasteTarget.focus();
+ document.execCommand('paste');
+ return clipboardPasteTarget.innerText;
}
// Command handlers