Skip to content
This repository has been archived by the owner on Jul 5, 2018. It is now read-only.

Commit

Permalink
Support IPV6 in Services/GeolocationMaxmindService.cs
Browse files Browse the repository at this point in the history
  • Loading branch information
Samuel Mead committed Mar 8, 2017
1 parent 857d44a commit e90a6c0
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion Services/GeolocationMaxmindService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,8 @@ public GeoLocationResult GetGeoLocation(IPAddress address, NameValueCollection c
throw new ArgumentException(string.Format("db does not exist at location {0}", maxMindDatabaseFileName));
}

if (address.AddressFamily != AddressFamily.InterNetwork)
if (address.AddressFamily != AddressFamily.InterNetwork &&
address.AddressFamily != AddressFamily.InterNetworkV6)
{
return null;
}
Expand Down

0 comments on commit e90a6c0

Please sign in to comment.