From 051e4408450715ad080ed9bfd2593eb288174c0f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?John=20Molakvo=C3=A6=20=28skjnldsv=29?= Date: Thu, 13 Sep 2018 09:44:23 +0200 Subject: [PATCH] Js fix MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: John Molakvoæ (skjnldsv) --- js/documents.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/js/documents.js b/js/documents.js index 278355552..13228813a 100644 --- a/js/documents.js +++ b/js/documents.js @@ -484,7 +484,9 @@ var documentsMain = { } // iOS webkit fallback - if (window.webkit.messageHandlers.RichDocumentsMobileInterface) { + if (window.webkit + && window.webkit.messageHandlers + && window.webkit.messageHandlers.RichDocumentsMobileInterface) { if (msgId === 'UI_Close') { window.webkit.messageHandlers.RichDocumentsMobileInterface.postMessage('close'); } else if (msgId === 'UI_InsertGraphic') {