Commit 60054545 authored by Jean-Francois Dockes's avatar Jean-Francois Dockes
Browse files

Guard against empty doc fmtime field

parent 788061bd
......@@ -84,6 +84,8 @@ def select(ls, invalid=[None]):
return value
def timestr(secs, fmt):
if secs == '' or secs is None:
secs = '0'
t = time.gmtime(int(secs))
return time.strftime(fmt, t)
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment