Add a trailing quote if one is missing in a Say action.

This commit is contained in:
raeleus 2024-10-10 22:33:51 -07:00
parent f3fc636e10
commit 703ed00387

View file

@ -82,6 +82,7 @@ function sanitizeText(text) {
text = text.replace(/^\s*>\s/, "")
text = text.replace(/says? "/, "")
text = text.replace(/"\n$/, "")
if (text.split('"').length - 1 % 2 == 1) text += '"'
} else if (/^\s*>\s.*/.test(text)) {
text = text.replace(/^\s*>\s/, "")
text = text.replace(/\.?\n$/, "")