Avoid rewriting every file at startup

This commit is contained in:
vylion 2020-10-26 23:19:37 +01:00
parent 3402aa6899
commit 06c9412b4a

View file

@ -123,6 +123,7 @@ class Archivist(object):
self.logger.info("Successfully passed through {} ({}) chat.\n".format(cid, reader.title()))
if self.bypass: # I forgot what I made this for
reader.set_period(random.randint(self.max_period // 2, self.max_period))
self.store(*reader.archive())
elif reader.period() > self.max_period:
reader.set_period(self.max_period)
self.store(*reader.archive())