print "comic db creation failed after copy"
+ def get_stored(self):
+ try:
+ idf = open(self.dbfile + ".last", 'r')
+ retval = idf.read()
+ print "got stored index :" + str(retval)
+ idf.close()
+ return int(retval)
+ except:
+ return 0
+
+ def store_last(self, sid = 0):
+ try:
+ idf = open(self.dbfile + ".last", 'w')
+ if sid > 0:
+ idf.write(str(sid))
+ else:
+ idf.write(str(self.currentcomic))
+ idf.close()
+ return True
+ except:
+ return False
+
+
def get_comic(self):
- print str(self.currentcomic)
+ # print str(self.currentcomic)
if self.currentcomic < 0:
self.currentcomic = 0
if len(self.db) > 0: