Skip to content

Commit 09c6755

Browse files
committed
fix: 0div
1 parent 268793a commit 09c6755

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

typescript/src/controller.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -278,6 +278,9 @@ export class Controller<T extends FactorsType> {
278278
}
279279

280280
get progress() {
281+
if (this.numAllChunks === 0) {
282+
return 0;
283+
}
281284
return 1 - this.incomplete.size / this.numAllChunks;
282285
}
283286

0 commit comments

Comments
 (0)