From 1df49c6f324173bca04ad7ed86a217248c232802 Mon Sep 17 00:00:00 2001 From: Delaine Wendling Date: Thu, 24 Jun 2021 13:07:13 -0500 Subject: [PATCH] updating latitude bounds --- geohash.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/geohash.py b/geohash.py index 72b0366..6dbd713 100644 --- a/geohash.py +++ b/geohash.py @@ -75,7 +75,7 @@ def _encode_i2c(lat,lon,lat_length,lon_length): return ret[::-1] def encode(latitude, longitude, precision=12): - if latitude >= 90.0 or latitude < -90.0: + if latitude > 90.0 or latitude < -90.0: raise Exception("invalid latitude.") while longitude < -180.0: longitude += 360.0