ensure that content is iterable

This commit is contained in:
siikamiika 2019-08-15 15:35:23 +03:00
parent 0a9b673e27
commit 609dbf6a81

View File

@ -240,7 +240,7 @@ class TextSourceElement {
let consumed = 0;
let content = '';
for (let currentChar of this.content) {
for (let currentChar of this.content || '') {
if (consumed >= length) {
break;
} else if (!currentChar.match(IGNORE_TEXT_PATTERN)) {