mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-20 01:38:19 +08:00
core: fix argument validation for script
This commit is contained in:
1 parent
61597151a8
commit
c43663a1d1
5 files changed
+5
-13
No files matched your search
@@ -108,7 +108,7 @@ class SystemScriptHandler extends SystemHandler {
|
||||
if (!global.Hydro.script[id]) throw new ValidationError('id');
|
||||
const args = JSON.parse(raw);
|
||||
validate(global.Hydro.script[id].validate, args);
|
||||
const rid = await record.add(domainId, -1, this.user._id, '-', id, false, 'raw');
|
||||
const rid = await record.add(domainId, -1, this.user._id, '-', id, false, raw);
|
||||
const report = (data) => judge.next({ domainId, rid, ...data });
|
||||
report({ message: `Running script: ${id} `, status: STATUS.STATUS_JUDGING });
|
||||
const start = new Date().getTime();
|
||||
|
||||
Reference in new issue
Block a user