Skip to content

Commit

Permalink
Update DownloadHelper.cs
Browse files Browse the repository at this point in the history
  • Loading branch information
laolarou726 committed Jan 24, 2025
1 parent c8399fc commit b51c318
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion ProjBobcat/ProjBobcat/Class/Helper/DownloadHelper.cs
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ public static async Task DownloadData(AbstractDownloadBase downloadFile, Downloa
await destStream.WriteAsync(buffer.Memory[..bytesRead], cts.Token);

var duration = Stopwatch.GetElapsedTime(startTime);
var elapsedTime = duration.TotalSeconds == 0 ? 1 : duration.TotalSeconds;
var elapsedTime = duration.TotalSeconds < 0.0001 ? 1 : duration.TotalSeconds;

averageSpeed = responseLength / elapsedTime;

Expand Down

0 comments on commit b51c318

Please sign in to comment.