fix: Add optional chaining to prevent errors in isLongText function

This commit is contained in:
newtextdoc1111
2025-07-13 22:48:36 +09:00
parent 944ecff9ce
commit 8b38ade1b9
+1 -1
View File
@@ -52,7 +52,7 @@ const REG_WILDCARD_SIMPLE_WORD = /[^{}_|]+/g;
* @return {boolean} True if the text is longer than the maximum tag length, false otherwise.
*/
export function isLongText(text) {
return text.length > settingValues._maxTagLength;
return text?.length > settingValues._maxTagLength;
}
/**