core: fix type errors in migrations

This commit is contained in:
Abdullah Atta
2024-11-12 13:09:33 +05:00
committed by Abdullah Atta
parent 7acb0a8c0f
commit 7437b29518

View File

@@ -624,6 +624,7 @@ function replaceDateEditedWithDateModified(removeDateEditedProperty = false) {
function wrapTablesWithDiv(html: string) {
const document = parseHTML(html);
if (!document) return html;
const tables = document.getElementsByTagName("table");
for (const table of tables) {
table.setAttribute("contenteditable", "true");
@@ -640,6 +641,7 @@ function wrapTablesWithDiv(html: string) {
function removeToxClassFromChecklist(html: string): string {
const document = parseHTML(html);
if (!document) return html;
const checklists = document.querySelectorAll(
".tox-checklist,.tox-checklist--checked"
);
@@ -686,6 +688,7 @@ export function tinyToTiptap(html: string) {
);
const document = parseHTML(html);
if (!document) return html;
const tables = document.querySelectorAll("table");
for (const table of tables) {