From c3dabb90825c93e74f0a10651e5a906413c69169 Mon Sep 17 00:00:00 2001 From: Thor77 Date: Sun, 12 Jun 2016 17:54:32 +0200 Subject: [PATCH] give .total_seconds() to sort_clients instead of datetime.timedelta --- tsstats/template.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tsstats/template.py b/tsstats/template.py index 598779d..9048147 100644 --- a/tsstats/template.py +++ b/tsstats/template.py @@ -27,7 +27,7 @@ def render_template(clients, output, title='TeamspeakStats'): ''' # prepare clients clients_onlinetime_ = sort_clients( - clients, lambda c: c.onlinetime + clients, lambda c: c.onlinetime.total_seconds() ) clients_onlinetime = [ (client, seconds_to_text(onlinetime))