Skip to content

Commit

Permalink
Fix
Browse files Browse the repository at this point in the history
  • Loading branch information
bachya committed Nov 8, 2022
1 parent 17fff44 commit 274129d
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions aiopurpleair/util/geo.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,8 @@ def __post_init__(self) -> None:
("latitude", self.latitude_radians, MINIMUM_LATITUDE, MAXIMUM_LATITUDE),
("longitude", self.longitude_radians, MINIMUM_LONGITUDE, MAXIMUM_LONGITUDE),
):
if minimum <= value <= maximum:
continue
raise ValueError(f"Invalid {kind}: {value} radians")
if value < minimum or value > maximum:
raise ValueError(f"Invalid {kind}: {value} radians")

@classmethod
def from_degrees(
Expand Down

0 comments on commit 274129d

Please sign in to comment.