mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-20 09:46:28 +08:00
优化rating计算速度
This commit is contained in:
1 parent
45f1184d68
commit
55912b087d
22 files changed
+309
-178
No files matched your search
@@ -282,7 +282,7 @@ class ContestCreateHandler extends ContestHandler {
|
||||
}
|
||||
|
||||
async post({
|
||||
domainId, title, content, rule, beginAtDate, beginAtTime, duration, pids,
|
||||
domainId, title, content, rule, beginAtDate, beginAtTime, duration, pids, rated = false,
|
||||
}) {
|
||||
let beginAt;
|
||||
try {
|
||||
@@ -294,7 +294,7 @@ class ContestCreateHandler extends ContestHandler {
|
||||
pids = await this.verifyProblems(domainId, pids);
|
||||
const tid = await contest.add(
|
||||
domainId, title, content,
|
||||
this.user._id, rule, beginAt, endAt, pids,
|
||||
this.user._id, rule, beginAt, endAt, pids, rated,
|
||||
);
|
||||
this.response.body = { tid };
|
||||
this.response.redirect = `/c/${tid}`;
|
||||
|
||||
Reference in new issue
Block a user