Skip to content

Commit c14b1cd

Browse files
committed
fix assertion
1 parent 15f4b73 commit c14b1cd

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/command/render/pandoc.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1230,9 +1230,9 @@ export async function runPandoc(
12301230
!isBeamerOutput(options.format.pandoc)
12311231
) {
12321232
const docClass = pandocMetadata[kDocumentClass];
1233-
assert(typeof docClass === "string");
1233+
assert(!docClass || typeof docClass === "string");
12341234
const isPrintDocumentClass = docClass &&
1235-
["book", "scrbook"].includes(docClass);
1235+
["book", "scrbook"].includes(docClass as string);
12361236

12371237
if (!isPrintDocumentClass) {
12381238
if (pandocMetadata[kColorLinks] === undefined) {

0 commit comments

Comments
 (0)