diff options
author | jwansek <eddie.atten@yahoo.co.uk> | 2018-12-31 23:27:11 +0000 |
---|---|---|
committer | jwansek <eddie.atten@yahoo.co.uk> | 2018-12-31 23:27:11 +0000 |
commit | 388d15fe0640bb50438fa2d3640b2f29bc07ada7 (patch) | |
tree | 18a0195f38701691b72bf0044fdd7b583fb98df6 /database.py | |
parent | 0f2abe1fa7d082475c3710c199387f02be1143cd (diff) | |
download | SmallYTChannelBot-388d15fe0640bb50438fa2d3640b2f29bc07ada7.tar.gz SmallYTChannelBot-388d15fe0640bb50438fa2d3640b2f29bc07ada7.zip |
removed posts with insufficient lambda, etc.
Diffstat (limited to 'database.py')
-rw-r--r-- | database.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/database.py b/database.py index 0048296..26b8e43 100644 --- a/database.py +++ b/database.py @@ -87,3 +87,9 @@ class Database: def get_stats(self): self.cursor.execute("SELECT * FROM stats;") return self.cursor.fetchall() + + def user_given_lambda(self, user, permalink): + links = self.get_lambda(user)[1] + return permalink in links or permalink.replace("https://www.reddit.com", "") in links + + |