mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-20 01:38:19 +08:00
core, ui, judge: rewrite http & ws layer (#352)
This commit is contained in:
1 parent
3d2384f31a
commit
5af082eac8
37 files changed
+868
-889
No files matched your search
@@ -40,8 +40,8 @@ registerResolver(
|
||||
'Query', 'contest(id: ObjectID!)', 'Contest',
|
||||
async (arg, ctx) => {
|
||||
arg.id = new ObjectID(arg.id);
|
||||
ctx.tdoc = await contest.get(ctx.domainId, new ObjectID(arg.id));
|
||||
if (!ctx.tdoc) throw new ContestNotFoundError(ctx.domainId, arg.id);
|
||||
ctx.tdoc = await contest.get(ctx.args.domainId, new ObjectID(arg.id));
|
||||
if (!ctx.tdoc) throw new ContestNotFoundError(ctx.args.domainId, arg.id);
|
||||
return ctx.tdoc;
|
||||
},
|
||||
'Get a contest by ID',
|
||||
|
||||
Reference in new issue
Block a user