Skip to content

Commit fb819b4

Browse files
committed
Return escaped HTML for unrecognized languages
1 parent 7ae1a17 commit fb819b4

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

index.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,10 @@ function highlight(lang, code) {
2929
return hljs.highlight(lang, code).value;
3030
} catch(e) { }
3131

32-
return code;
32+
return {
33+
body: code,
34+
html: false
35+
};
3336
}
3437

3538

0 commit comments

Comments
 (0)