mirror of
https://gitlab.com/Hukuta47/cartrix.git
synced 2026-12-05 20:40:55 +00:00
ф
This commit is contained in:
1 parent
e8529ee92a
commit
eddb735070
5 files changed
+4
-15
No files matched your search
@@ -146,18 +146,5 @@ namespace CartriX.Api.Services
|
||||
return null;
|
||||
}
|
||||
}
|
||||
private async Task<string?> GetHostnameFromIpAsync(IPAddress ipAddress)
|
||||
{
|
||||
try
|
||||
{
|
||||
IPHostEntry entry = Dns.GetHostEntry(ipAddress);
|
||||
return entry.HostName;
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
Console.WriteLine($"error: {ex.Message}");
|
||||
return null;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user