Fix regression taht caused usbms based drivers to not get correct timestamp for files on device

This commit is contained in:
Kovid Goyal 2010-05-17 13:06:39 -06:00
parent 38b1f35ff7
commit a5b4012059

View File

@ -38,8 +38,10 @@ class Book(MetaInformation):
self.lpath = lpath
self.mime = mime_type_ext(path_to_ext(lpath))
self.size = size # will be set later if None
try:
self.datetime = time.gmtime(os.path.getctime(self.path))
except:
self.datetime = time.gmtime()
if other:
self.smart_update(other)