mirror of
https://github.com/Stone-Red-Code/HyperbolicDownloader.git
synced 2026-09-04 00:56:09 +02:00
Update naming and add auto retry if hash is wrong
This commit is contained in:
@@ -26,7 +26,7 @@ internal class BroadcastClient
|
||||
|
||||
if (ip4Address is null)
|
||||
{
|
||||
ApiManager.SendMessageNewLine("Could not find suitable network adapter!", NotificationMessageType.Error);
|
||||
ApiManager.SendNotificationMessageNewLine("Could not find suitable network adapter!", NotificationMessageType.Error);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -34,7 +34,7 @@ internal class BroadcastClient
|
||||
|
||||
if (addressInformation is null)
|
||||
{
|
||||
ApiManager.SendMessageNewLine("Could not find suitable network adapter!", NotificationMessageType.Error);
|
||||
ApiManager.SendNotificationMessageNewLine("Could not find suitable network adapter!", NotificationMessageType.Error);
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
@@ -53,7 +53,7 @@ public class HostsManager
|
||||
int activeHostsCount = 0;
|
||||
foreach (NetworkSocket host in hosts)
|
||||
{
|
||||
ApiManager.SendMessage($"{host.IPAddress}:{host.Port} > ???", NotificationMessageType.Warning);
|
||||
ApiManager.SendNotificationMessage($"{host.IPAddress}:{host.Port} > ???", NotificationMessageType.Warning);
|
||||
using TcpClient tcpClient = new TcpClient();
|
||||
|
||||
try
|
||||
@@ -62,7 +62,7 @@ public class HostsManager
|
||||
Console.CursorLeft = 0;
|
||||
if (tcpClient.Connected)
|
||||
{
|
||||
ApiManager.SendMessageNewLine($"{host.IPAddress}:{host.Port} > Active", NotificationMessageType.Success);
|
||||
ApiManager.SendNotificationMessageNewLine($"{host.IPAddress}:{host.Port} > Active", NotificationMessageType.Success);
|
||||
host.LastActive = DateTime.Now;
|
||||
activeHostsCount++;
|
||||
}
|
||||
@@ -72,7 +72,7 @@ public class HostsManager
|
||||
{
|
||||
hostsToRemove.Add(host);
|
||||
}
|
||||
ApiManager.SendMessageNewLine($"{host.IPAddress}:{host.Port} > Inactive", NotificationMessageType.Error);
|
||||
ApiManager.SendNotificationMessageNewLine($"{host.IPAddress}:{host.Port} > Inactive", NotificationMessageType.Error);
|
||||
}
|
||||
}
|
||||
catch
|
||||
@@ -82,7 +82,7 @@ public class HostsManager
|
||||
hostsToRemove.Add(host);
|
||||
}
|
||||
Console.CursorLeft = 0;
|
||||
ApiManager.SendMessageNewLine($"{host.IPAddress}:{host.Port} > Inactive", NotificationMessageType.Error);
|
||||
ApiManager.SendNotificationMessageNewLine($"{host.IPAddress}:{host.Port} > Inactive", NotificationMessageType.Error);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user