diff --git a/src/doc.js b/src/doc.js index 98b77fe..4c8d54a 100644 --- a/src/doc.js +++ b/src/doc.js @@ -236,7 +236,7 @@ var prototype = node.derive({ .per(this.runs, this) .first(); text = [ - Object.create(sampleRun, { text: { value: text } }) + sampleRun ? Object.create(sampleRun, { text: { value: text } }) : { text: text } ]; } else if (!Array.isArray(text)) { text = [{ text: text }];