From 10950ce8b9b3239da076db6e4e96e2aaaf6ef8e7 Mon Sep 17 00:00:00 2001 From: undefined Date: Mon, 11 Apr 2022 16:49:17 +0800 Subject: [PATCH] core: fix skipUpload types --- packages/hydrooj/src/handler/problem.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/hydrooj/src/handler/problem.ts b/packages/hydrooj/src/handler/problem.ts index 496d16821..282ed40c3 100644 --- a/packages/hydrooj/src/handler/problem.ts +++ b/packages/hydrooj/src/handler/problem.ts @@ -853,7 +853,7 @@ export class ProblemCreateHandler extends Handler { if (this.user._files.find((i) => i.name === file)) { tasks.push( storage.rename(`user/${this.user._id}/${file}`, `problem/${domainId}/${docId}/additional_file/${file}`, this.user._id) - .then(() => problem.addAdditionalFile(domainId, docId, file, '', true)), + .then(() => problem.addAdditionalFile(domainId, docId, file, '', this.user._id, true)), user.setById(this.user._id, { _files: this.user._files.filter((i) => i.name !== file) }), ); }