]> git.parisson.com Git - telemeta.git/commitdiff
bugfix
authorGuillaume Pellerin <yomguy@parisson.com>
Wed, 1 Dec 2010 10:29:45 +0000 (11:29 +0100)
committerGuillaume Pellerin <yomguy@parisson.com>
Wed, 1 Dec 2010 10:29:45 +0000 (11:29 +0100)
telemeta/web/base.py

index 52a0dc94f787bf44beab204f16c633ea8ba442f4..302bf7384675569a0bb629a8942b68d89703fd14 100644 (file)
@@ -131,8 +131,11 @@ class WebView:
             if not item.approx_duration:
                 for analyzer in analyzers:
                     if analyzer['id'] == 'duration':
-                        approx_value = int(round(analyzer['value']))
-                        item.approx_duration = approx_value
+                        value = analyzer['value']
+                        time = value.split(':')
+                        time[2] = time[2].split('.')[0]
+                        time = ':'.join(time)
+                        item.approx_duration = time
                         item.save()
         else:
             analyzers = []