Don't floor newsletter start date

This commit is contained in:
JonnyWong16 2020-09-27 17:44:11 -07:00
parent 2a4b48d0fa
commit ad6e314343
No known key found for this signature in database
GPG key ID: B1F1F9807184697A

View file

@ -403,9 +403,9 @@ class Newsletter(object):
if self.start_date is None: if self.start_date is None:
if self.config['time_frame_units'] == 'days': if self.config['time_frame_units'] == 'days':
self.start_date = self.end_date.shift(days=-self.config['time_frame']+1).floor('day') self.start_date = self.end_date.shift(days=-self.config['time_frame'])
else: else:
self.start_date = self.end_date.shift(hours=-self.config['time_frame']).floor('hour') self.start_date = self.end_date.shift(hours=-self.config['time_frame'])
self.end_time = self.end_date.timestamp self.end_time = self.end_date.timestamp
self.start_time = self.start_date.timestamp self.start_time = self.start_date.timestamp