From 1c50e615cf67c3a2a4ef952ad4087a4d75951a07 Mon Sep 17 00:00:00 2001 From: o Date: Sat, 22 Apr 2017 19:27:31 -0400 Subject: [PATCH] Fixing math used to calculate human_duration There are 86400 seconds in a day --- plexpy/helpers.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/plexpy/helpers.py b/plexpy/helpers.py index 07a6fb13..90c091d1 100644 --- a/plexpy/helpers.py +++ b/plexpy/helpers.py @@ -204,10 +204,10 @@ def human_duration(s, sig='dhms'): hd = '' if str(s).isdigit() and s > 0: - d = int(s / 84600) - h = int((s % 84600) / 3600) - m = int(((s % 84600) % 3600) / 60) - s = int(((s % 84600) % 3600) % 60) + d = int(s / 86400) + h = int((s % 86400) / 3600) + m = int(((s % 86400) % 3600) / 60) + s = int(((s % 86400) % 3600) % 60) hd_list = [] if sig >= 'd' and d > 0: