###############################################################################
+def byebye():
+ if not Options["No-Action"]:
+ # Clean out the queue files
+ session = DBConn().session()
+ session.execute("DELETE FROM changes_pending_files WHERE id NOT IN (SELECT file_id FROM changes_pending_files_map )")
+ session.commit()
+
+
+
def action(u, session):
cnf = Config()
holding = Holding()
session.commit()
u.remove()
elif answer == 'Q':
- sys.exit(0)
+ byebye()
session.commit()
utils.size_type(int(summarystats.accept_bytes)))
Logger.log(["total", summarystats.accept_count, summarystats.accept_bytes])
- if not Options["No-Action"]:
- # Clean out the queue files
- session = DBConn().session()
- session.execute("DELETE FROM changes_pending_files WHERE id NOT IN (SELECT file_id FROM changes_pending_files_map )")
- session.commit()
+ byebye()
+ if not Options["No-Action"]:
if log_urgency:
UrgencyLog().close()
+
Logger.close()
###############################################################################