diff --git a/timebot/timebot.py b/timebot/timebot.py index 1fa9834..02bf556 100644 --- a/timebot/timebot.py +++ b/timebot/timebot.py @@ -293,7 +293,11 @@ class TimeBot: self.mobatime_api.save_entry(punch_datetime, BREAK_END_ENTRY_CODE_ID, note="pause ende").raise_for_status() def smart_punch(self, punch_datetime): - last_punch = self.mobatime_api.get_entries(1, punch_datetime.replace(hour=0, minute=0, second=0, microsecond=0)) + last_punch = self.mobatime_api.get_entries( + 1, + start_date=punch_datetime.replace(hour=0, minute=0, second=0, microsecond=0), + end_date=punch_datetime.replace(hour=0, minute=0, second=0, microsecond=0), + ) method = None if not last_punch or last_punch[0]["entryNumber"] is None: self.logger.debug("could not detect any time entry for today... punching in")