mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-20 01:38:19 +08:00
judge: revert last commit
This commit is contained in:
1 parent
fc799927d6
commit
3fc18d7539
1 file changed
+1
-3
@@ -218,9 +218,7 @@ export async function run(execute: string, params?: Parameter): Promise<SandboxA
|
|||||||
const queue = new PQueue({ concurrency: getConfig('concurrency') || getConfig('parallelism') });
|
const queue = new PQueue({ concurrency: getConfig('concurrency') || getConfig('parallelism') });
|
||||||
|
|
||||||
export function runQueued(execute: string, params?: Parameter, priority = 0) {
|
export function runQueued(execute: string, params?: Parameter, priority = 0) {
|
||||||
return queue.add(() => {
|
return queue.add(() => run(execute, params), { priority }) as Promise<SandboxAdaptedResult>;
|
||||||
const result = await run(execute, params), { priority }
|
|
||||||
}) as Promise<SandboxAdaptedResult>;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
export async function versionCheck(reportWarn: (str: string) => void, reportError = reportWarn) {
|
export async function versionCheck(reportWarn: (str: string) => void, reportError = reportWarn) {
|
||||||
|
|||||||
Reference in new issue
Block a user