mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-20 01:38:19 +08:00
core: fix contest.isOngoing
This commit is contained in:
1 parent
7d1ddff47b
commit
62dda5fd4f
2 files changed
+2
-2
No files matched your search
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "hydrooj",
|
"name": "hydrooj",
|
||||||
"version": "2.14.2",
|
"version": "2.14.3",
|
||||||
"bin": "bin/hydrooj.js",
|
"bin": "bin/hydrooj.js",
|
||||||
"main": "dist/loader.js",
|
"main": "dist/loader.js",
|
||||||
"typings": "dist/loader.d.ts",
|
"typings": "dist/loader.d.ts",
|
||||||
|
|||||||
@@ -272,7 +272,7 @@ class ContestProblemSubmitHandler extends ContestProblemHandler {
|
|||||||
@param('tid', Types.ObjectID)
|
@param('tid', Types.ObjectID)
|
||||||
@param('pid', Types.UnsignedInt)
|
@param('pid', Types.UnsignedInt)
|
||||||
async prepare(domainId: string, tid: ObjectID, pid: number) {
|
async prepare(domainId: string, tid: ObjectID, pid: number) {
|
||||||
if (contest.isOngoing(this.tdoc)) throw new ContestNotLiveError(this.tdoc.docId);
|
if (!contest.isOngoing(this.tdoc)) throw new ContestNotLiveError(this.tdoc.docId);
|
||||||
let rdocs = [];
|
let rdocs = [];
|
||||||
if (this.canShowRecord(this.tdoc)) {
|
if (this.canShowRecord(this.tdoc)) {
|
||||||
rdocs = await record.getUserInProblemMulti(
|
rdocs = await record.getUserInProblemMulti(
|
||||||
|
|||||||
Reference in new issue
Block a user