mirror of
https://github.com/Ombi-app/Ombi.git
synced 2025-08-19 12:59:39 -07:00
Removed percentage
This commit is contained in:
parent
33375cbc7b
commit
e661eaccbb
1 changed files with 0 additions and 12 deletions
|
@ -195,20 +195,8 @@ namespace Ombi.Schedule.Jobs.Ombi
|
||||||
{
|
{
|
||||||
using (var client = new WebClient())
|
using (var client = new WebClient())
|
||||||
{
|
{
|
||||||
client.DownloadProgressChanged += DownloadProgressChanged;
|
|
||||||
|
|
||||||
await client.DownloadFileTaskAsync(requestUri, filename);
|
await client.DownloadFileTaskAsync(requestUri, filename);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
private static void DownloadProgressChanged(object sender, DownloadProgressChangedEventArgs e)
|
|
||||||
{
|
|
||||||
var bytesIn = double.Parse(e.BytesReceived.ToString());
|
|
||||||
var totalBytes = double.Parse(e.TotalBytesToReceive.ToString());
|
|
||||||
var percentage = bytesIn / totalBytes * 100;
|
|
||||||
|
|
||||||
Ctx.WriteProgressBar("Download", percentage);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
Loading…
Add table
Add a link
Reference in a new issue