Fix "ValueError: invalid literal for int() with base 10" // Resolve #2061

This commit is contained in:
Ivan Kravets
2019-01-23 17:54:45 +02:00
parent 3cc996d89f
commit eb57e14ac1

View File

@ -233,10 +233,13 @@ class ContentCache(object):
if "=" not in line:
continue
expire, path = line.split("=")
if time() < int(expire) and isfile(path) and \
path not in paths_for_delete:
newlines.append(line)
continue
try:
if time() < int(expire) and isfile(path) and \
path not in paths_for_delete:
newlines.append(line)
continue
except ValueError:
pass
found = True
if isfile(path):
try: