mirror of
https://github.com/Prowlarr/Prowlarr.git
synced 2026-04-23 22:45:06 -04:00
Use 'var' instead of explicit type
(cherry picked from commit 12374f7f0038e5b25548f5ab3f71122410832393)
This commit is contained in:
@@ -139,13 +139,13 @@ namespace Prowlarr.Http.Extensions
|
||||
|
||||
public static string GetHostName(this HttpRequest request)
|
||||
{
|
||||
string ip = request.GetRemoteIP();
|
||||
var ip = request.GetRemoteIP();
|
||||
|
||||
try
|
||||
{
|
||||
IPAddress myIP = IPAddress.Parse(ip);
|
||||
IPHostEntry getIPHost = Dns.GetHostEntry(myIP);
|
||||
List<string> compName = getIPHost.HostName.ToString().Split('.').ToList();
|
||||
var myIP = IPAddress.Parse(ip);
|
||||
var getIPHost = Dns.GetHostEntry(myIP);
|
||||
var compName = getIPHost.HostName.ToString().Split('.').ToList();
|
||||
return compName.First();
|
||||
}
|
||||
catch
|
||||
|
||||
Reference in New Issue
Block a user