[Libreoffice-commits] online.git: loleaflet/src
Henry Castro (via logerrit)
logerrit at kemper.freedesktop.org
Thu Mar 19 18:18:38 UTC 2020
loleaflet/src/control/Control.PartsPreview.js | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
New commits:
commit af338541a88d4f90d1859ba60d8de6e3e90f1423
Author: Henry Castro <hcastro at collabora.com>
AuthorDate: Thu Mar 19 11:52:54 2020 -0400
Commit: Henry Castro <hcastro at collabora.com>
CommitDate: Thu Mar 19 19:18:18 2020 +0100
loleaflet: check if "parts" variable is a number of the preview thumbnail
While I was debugging Impress, I received unexpected "undefined"
value of the variable "parts"
Change-Id: Id8b6737155516fd0d8cfaa350170e9c631c55dcf
Reviewed-on: https://gerrit.libreoffice.org/c/online/+/90756
Tested-by: Henry Castro <hcastro at collabora.com>
Reviewed-by: Henry Castro <hcastro at collabora.com>
diff --git a/loleaflet/src/control/Control.PartsPreview.js b/loleaflet/src/control/Control.PartsPreview.js
index 3ed9f09d4..3e31133e7 100644
--- a/loleaflet/src/control/Control.PartsPreview.js
+++ b/loleaflet/src/control/Control.PartsPreview.js
@@ -65,7 +65,7 @@ L.Control.PartsPreview = L.Control.extend({
var selectedPart = e.selectedPart;
var selectedParts = e.selectedParts;
var docType = e.docType;
- if (docType === 'text') {
+ if (docType === 'text' || isNaN(parts)) {
return;
}
More information about the Libreoffice-commits
mailing list