mirror of
https://github.com/kevin-DL/sapper.git
synced 2026-01-15 12:24:47 +00:00
better unicode handling - fixes #347, i think
This commit is contained in:
@@ -185,7 +185,8 @@ function serve({ prefix, pathname, cache_control }: {
|
||||
const type = lookup(req.path);
|
||||
|
||||
try {
|
||||
const data = read(req.path.slice(1));
|
||||
const file = decodeURIComponent(req.path.slice(1));
|
||||
const data = read(file);
|
||||
|
||||
res.setHeader('Content-Type', type);
|
||||
res.setHeader('Cache-Control', cache_control);
|
||||
|
||||
Reference in New Issue
Block a user