From 3a930dfdb199289a77d98246345f1a9189de62a7 Mon Sep 17 00:00:00 2001 From: Holden Rohrer Date: Sun, 19 Jan 2020 23:42:27 +0000 Subject: uncaught typo I thought I fixed --- tools/schedule.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'tools') diff --git a/tools/schedule.js b/tools/schedule.js index bbc2a08..e2af9db 100644 --- a/tools/schedule.js +++ b/tools/schedule.js @@ -74,7 +74,7 @@ exports.Queue = function(delayms, maxExport, call){ // Step 2: Start at lowest, and pop all until job.data.length>job.normweight*num (decreasing num as popping and recalc job.normweight). Delete the job. let weightsum = jobq.map(job => job.wt).reduce((acc, cur)=>acc+cur); while (jobq[0] && jobq[0].data.length<(jobq[0].wacc+jobq[0].wt*num/weightsum)){ - weightsum -= job.wt; + weightsum -= jobq[0].wt; dequeued.push(...jobq.shift().data); } -- cgit