Skip to content

Commit c05c24e

Browse files
committed
fix: xpi sleep time
1 parent 648d5ac commit c05c24e

1 file changed

Lines changed: 7 additions & 1 deletion

File tree

scripts/pack-utils/xpi.mjs

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,13 @@ async function packXpi({
2424
if (waitSubmit.length > 0) {
2525
const last = waitSubmit[waitSubmit.length - 1];
2626
// wait 60s for AMO submit
27-
await sleep(last + 60000);
27+
const nextRun = last + 60000;
28+
if (Date.now() < nextRun) {
29+
console.log(
30+
`[xpi] [${extensionConfig.id}] wait ${nextRun - Date.now()}ms`,
31+
);
32+
await sleep(nextRun - Date.now());
33+
}
2834
}
2935

3036
console.log(`[xpi] [${extensionConfig.id}] start signAddon`);

0 commit comments

Comments
 (0)