mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-20 01:38:19 +08:00
core: fix contest export for file submission
This commit is contained in:
1 file changed
+1
-1
@@ -536,7 +536,7 @@ export class ContestCodeHandler extends Handler {
|
||||
if (!id) return;
|
||||
zip.addFile(
|
||||
`${rnames[rdoc._id.toHexString()]}.${filename || 'txt'}`,
|
||||
await streamToBuffer(storage.get(id)),
|
||||
await streamToBuffer(await storage.get(`submission/${id}`)),
|
||||
);
|
||||
} else if (rdoc.code) {
|
||||
zip.addFile(`${rnames[rdoc._id.toHexString()]}.${rdoc.lang}`, Buffer.from(rdoc.code));
|
||||
|
||||
Reference in new issue
Block a user