Skip to content

Commit

Permalink
fix(#155): make live content accept empty strings
Browse files Browse the repository at this point in the history
  • Loading branch information
jannis-baum committed Aug 3, 2024
1 parent e5e853c commit 2188f9f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/routes/viewer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ router.post(/.*/, async (req: Request, res: Response) => {
content = readFileSync(path).toString();
}
const clients = clientsAt(path);
if (content) {
if (content !== undefined) {
const rendered = renderTextFile(content, path);
liveContent.set(path, rendered);
messageClients(clients, `UPDATE: ${rendered}`);
Expand Down

0 comments on commit 2188f9f

Please sign in to comment.