mirror of
https://github.com/dgtlmoon/changedetection.io.git
synced 2025-12-11 02:25:32 +00:00
Scrub dates: Fix date regex limit handler parsing
This commit is contained in:
@@ -316,7 +316,7 @@ def changedetection_app(config=None, datastore_o=None):
|
||||
# I noticed chrome will show '/' but actually submit '-'
|
||||
limit_date = limit_date.replace('-', '/')
|
||||
# In the case that :ss seconds are supplied
|
||||
limit_date = re.sub('(\d\d:\d\d)(:\d\d)', '\\1', limit_date)
|
||||
limit_date = re.sub(r'(\d\d:\d\d)(:\d\d)', '\\1', limit_date)
|
||||
|
||||
str_to_dt = datetime.datetime.strptime(limit_date, '%Y/%m/%d %H:%M')
|
||||
limit_timestamp = int(str_to_dt.timestamp())
|
||||
|
||||
Reference in New Issue
Block a user