fix container running

AuthorKonata <konata@posteo.jp>
Date
Commitd38316736d755efccd3d47719f89f0663fc96c14
Parent28cba6f
1 file changed, 2 insertions(+), 2 deletions(-)
▾Mserver/src/index.ts
@@ -77,7 +77,7 @@ const downloadHandler: DownloadHandler = async ({ headers, params, set, request
if (!headers.range) {
set.status = "OK";
return Bun.file(filePath);
return new ElysiaFile(filePath);
}
const rangeData = parseRange(fileSize, headers.range, { combine: true });
@@ -204,7 +204,7 @@ const app = setup
set.status = "OK";
if (playlist.length === 1) {
set.headers["Content-Disposition"] = `attachment; filename="${basename(playlist[0])}"`;
return Bun.file(path.join(musicRoot, playlist[0]));
return new ElysiaFile(path.join(musicRoot, playlist[0]));
}
set.headers["Content-Type"] = "application/x-tar";
set.headers["Content-Disposition"] = `attachment; filename="playlist.tar"`;