mirror of
https://github.com/Tautulli/Tautulli.git
synced 2025-07-15 01:32:57 -07:00
Change date calculation for watch statistics
This commit is contained in:
parent
23e177d1d3
commit
613f70886e
1 changed files with 1 additions and 2 deletions
|
@ -22,7 +22,6 @@ from future.builtins import str
|
|||
from future.builtins import object
|
||||
|
||||
import json
|
||||
from datetime import datetime, timedelta
|
||||
from itertools import groupby
|
||||
|
||||
import plexpy
|
||||
|
@ -311,7 +310,7 @@ class DataFactory(object):
|
|||
monitor_db = database.MonitorDatabase()
|
||||
|
||||
time_range = helpers.cast_to_int(time_range)
|
||||
timestamp = int((datetime.now(tz=plexpy.SYS_TIMEZONE) - timedelta(days=time_range)).timestamp())
|
||||
timestamp = helpers.timestamp() - time_range * 24 * 60 * 60
|
||||
|
||||
stats_start = helpers.cast_to_int(stats_start)
|
||||
stats_count = helpers.cast_to_int(stats_count)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue