diff --git a/src/controllers/updateCell.js b/src/controllers/updateCell.js
index 26e7bfd..d120db4 100644
--- a/src/controllers/updateCell.js
+++ b/src/controllers/updateCell.js
@@ -213,7 +213,7 @@ export function luckysheetupdateCell(row_index1, col_index1, d, cover, isnotfocu
if((value == null || value.toString() == "") && !cover){
value = "
";
}
-
+ value = formula.xssDeal(value);
if(!checkProtectionCellHidden(row_index, col_index, Store.currentSheetIndex) && value.length>0 && value.substr(0, 63)=='='){
$("#luckysheet-rich-text-editor").html("");
}
diff --git a/src/global/formula.js b/src/global/formula.js
index 4d2c5ea..f38efe2 100644
--- a/src/global/formula.js
+++ b/src/global/formula.js
@@ -321,6 +321,10 @@ const luckysheetformula = {
sheetmanage.changeSheetExec(_this.rangetosheet);
}
},
+ xssDeal: function(str) {
+ if (typeof str !== 'string') return str;
+ return str.replace(/