commit: DETECTOR_HISTORY

This commit is contained in:
Alec Muffett 2019-11-21 13:06:02 +00:00
parent 864d3b00ab
commit 8db1e1bc98

View File

@ -20,6 +20,7 @@ RETRY_SLEEP = 60
RETRY_LIMIT = 6 RETRY_LIMIT = 6
PLACEHOLDER = '-' PLACEHOLDER = '-'
POOL_WORKERS = 10 POOL_WORKERS = 10
DETECTOR_HISTORY=14
YES = 'y' YES = 'y'
EMOJI_HTTP = ':wrench:' EMOJI_HTTP = ':wrench:'
@ -114,7 +115,7 @@ class Database:
self.commit() self.commit()
self.connection.close() self.connection.close()
def summary(self, url, limit=10): def summary(self, url, limit=DETECTOR_HISTORY):
params = { 'url': url, 'limit': limit } params = { 'url': url, 'limit': limit }
rows = self.cursor.execute(SUMMARY_SQL, params) rows = self.cursor.execute(SUMMARY_SQL, params)
return rows.fetchall() return rows.fetchall()