[Libreoffice-commits] online.git: Branch 'distro/collabora/co-4-2-0' - loleaflet/html loleaflet/js
Marco Cecchetti (via logerrit)
logerrit at kemper.freedesktop.org
Wed Dec 11 08:42:10 UTC 2019
loleaflet/html/loleaflet.html.m4 | 2 ++
loleaflet/js/global.js | 3 ++-
2 files changed, 4 insertions(+), 1 deletion(-)
New commits:
commit 9226497b40600b4612a302e46b91e1205d3fada8
Author: Marco Cecchetti <marco.cecchetti at collabora.com>
AuthorDate: Tue Dec 10 22:05:13 2019 +0100
Commit: Andras Timar <andras.timar at collabora.com>
CommitDate: Wed Dec 11 09:41:51 2019 +0100
fixing 2 minor console errors
Change-Id: Ie2449e33dd47511b2d8a65e1f929e69fece8a567
Reviewed-on: https://gerrit.libreoffice.org/84902
Reviewed-by: Andras Timar <andras.timar at collabora.com>
Tested-by: Andras Timar <andras.timar at collabora.com>
diff --git a/loleaflet/html/loleaflet.html.m4 b/loleaflet/html/loleaflet.html.m4
index 6fc5afbfa..7639bf908 100644
--- a/loleaflet/html/loleaflet.html.m4
+++ b/loleaflet/html/loleaflet.html.m4
@@ -24,6 +24,8 @@ ifelse(MOBILEAPP,[],
// result for future
window.WOPIpostMessageReady = false;
var PostMessageReadyListener = function(e) {
+ if (!(e && e.data))
+ return;
var msg = JSON.parse(e.data);
if (msg.MessageId === 'Host_PostmessageReady') {
window.WOPIPostmessageReady = true;
diff --git a/loleaflet/js/global.js b/loleaflet/js/global.js
index e44d613a6..bb751a76b 100644
--- a/loleaflet/js/global.js
+++ b/loleaflet/js/global.js
@@ -45,7 +45,8 @@
source: src,
line: row,
column: col
- }, desc = err.message || {}, stack = err.stack || {};
+ };
+ var desc = err ? err.message || {}: {}, stack = err ? err.stack || {}: {};
var log = 'jserror ' + JSON.stringify(data, null, 2) + '\n' + desc + '\n' + stack + '\n';
if (window.ThisIsAMobileApp) {
window.postMobileError(log);
More information about the Libreoffice-commits
mailing list