aboutsummaryrefslogtreecommitdiffstats
path: root/recipes/thelounge/webview-unsafe.js
diff options
context:
space:
mode:
Diffstat (limited to 'recipes/thelounge/webview-unsafe.js')
-rw-r--r--recipes/thelounge/webview-unsafe.js7
1 files changed, 7 insertions, 0 deletions
diff --git a/recipes/thelounge/webview-unsafe.js b/recipes/thelounge/webview-unsafe.js
new file mode 100644
index 0000000..3f1358a
--- /dev/null
+++ b/recipes/thelounge/webview-unsafe.js
@@ -0,0 +1,7 @@
1// Monkey patch ServiceWorker.postMessage so that it will actually post a notification in Ferdi:
2
3function newPostMessage(options) {
4 window.ferdi.displayNotification(options.title, options);
5}
6
7ServiceWorker.prototype.postMessage = newPostMessage;