Skip to content

Commit

Permalink
DB_ADDON: Fix Bug in database queries for "next"-function
Browse files Browse the repository at this point in the history
  • Loading branch information
sisamiwe committed Mar 7, 2024
1 parent bfc248b commit 3801933
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion db_addon/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2641,7 +2641,7 @@ def _query_log_timestamp(self, func: str, item_id: int, ts_start: int, ts_end: i
'last': 'LIMIT 1 ',
}

_where = "item_id = :item_id AND time < :ts_start " if func == "next" else "item_id = :item_id AND time BETWEEN :ts_start AND :ts_end "
_where = "item_id = :item_id AND time < :ts_end " if func == "next" else "item_id = :item_id AND time BETWEEN :ts_start AND :ts_end "

_db_table = 'log '

Expand Down

0 comments on commit 3801933

Please sign in to comment.