🐛 Trying to fix JSON float

This commit is contained in:
2025-09-07 12:16:28 +08:00
parent 4a27794ccc
commit 7452b14817
2 changed files with 8 additions and 5 deletions

View File

@@ -25,7 +25,7 @@ public class GeoIpService(IOptions<GeoIpOptions> options)
using var reader = new DatabaseReader(_databasePath);
var city = reader.City(ipAddress);
if (city?.Location == null || !city.Location.HasCoordinates)
if (city?.Location is not { HasCoordinates: true })
return null;
return _geometryFactory.CreatePoint(new Coordinate(