Skip to content

Commit

Permalink
fix: order of date/datetime checking in native evaluator
Browse files Browse the repository at this point in the history
  • Loading branch information
constantinius committed Feb 16, 2023
1 parent 94770d6 commit d37d7c8
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions pygeofilter/backends/native/evaluate.py
Original file line number Diff line number Diff line change
Expand Up @@ -329,15 +329,15 @@ def to_interval(value: MaybeInterval) -> InternalInterval:

return (low, high)

elif isinstance(value, datetime):
return (value, value)

elif isinstance(value, date):
return (
datetime.combine(value, time.min, timezone.utc),
datetime.combine(value, time.max, timezone.utc),
)

elif isinstance(value, datetime):
return (value, value)

elif value is None:
return (None, None)

Expand Down

0 comments on commit d37d7c8

Please sign in to comment.