Browse Source

Remove duplicate quote in logging lines

master
Burathar 4 years ago
parent
commit
48e25359da
  1. 2
      .gitignore
  2. 4
      app/database_cleaner.py

2
.gitignore vendored

@ -141,4 +141,4 @@ cython_debug/ @@ -141,4 +141,4 @@ cython_debug/
app.db
.vscode/
logs/

4
app/database_cleaner.py

@ -13,13 +13,13 @@ def remove_dead_urls(): @@ -13,13 +13,13 @@ def remove_dead_urls():
def check_url(url):
if url.death is not None:
if datetime.now() > url.death :
app.logger.info(f"Removed hash '{url.hash}'' because its retention time has passed.")
app.logger.info(f"Removed hash '{url.hash}' because its retention time has passed.")
db.session.delete(url)
db.session.commit()
return "Timeout"
if url.view_counter is not None:
if url.view_counter <= 0:
app.logger.info(f"Removed hash '{url.hash}'' because its viewcouner has run out.")
app.logger.info(f"Removed hash '{url.hash}' because its viewcouner has run out.")
db.session.delete(url)
db.session.commit()
return "Counter"

Loading…
Cancel
Save