Ignore empty crx files in calculating last crx file date.

This commit is contained in:
Achim D. Brucker 2017-07-04 09:30:33 +01:00
parent 939b29f55a
commit 30c0b92979
1 changed files with 1 additions and 1 deletions

View File

@ -183,7 +183,7 @@ def last_crx(archivedir, extid):
extid + ".tar")
if os.path.exists(tar):
t = tarfile.open(tar, 'r')
old_crxs = sorted([x.name for x in t.getmembers() if x.name.endswith(".crx")])
old_crxs = sorted([x.name for x in t.getmembers() if x.name.endswith(".crx") and x.size > 0])
t.close()
if old_crxs != []:
last_crx = old_crxs[-1]