diff --git a/app.py b/app.py index 6674bd5..b566916 100644 --- a/app.py +++ b/app.py @@ -84,6 +84,8 @@ def spam_detector(): result = "This message is probably not spam." # Fetch related spam messages using the input as the WHERE clause + c.execute(f"SELECT message FROM spam_messages WHERE message LIKE '%{message}%'") + related_spam_messages = [row[0] for row in c.fetchall()] # Fetch all spam messages