From c4dd58c6d0bfcc6d8d8c583ae36837a62a9e9695 Mon Sep 17 00:00:00 2001 From: AaronLieb Date: Fri, 11 Oct 2024 11:31:35 -0700 Subject: [PATCH] Fix bug related to double message after sending image --- database.py | 1 - main.py | 3 --- 2 files changed, 4 deletions(-) diff --git a/database.py b/database.py index 51de438..5d26b99 100644 --- a/database.py +++ b/database.py @@ -138,7 +138,6 @@ def get_winner_by_prompt(self, prompt_id: int) -> Pic | None: def get_submission_status(self, user_hash: str, prompt_id: int) -> bool: user = self.get_user_by_hash(user_hash) - print(user_hash) if user is None: return False pic = self.get_pic(str(user.username), prompt_id) diff --git a/main.py b/main.py index 0788b54..cfe5a77 100644 --- a/main.py +++ b/main.py @@ -78,9 +78,6 @@ async def receive_message( and MediaUrl0 is not None ): twilio_client.handle_image(From, MediaUrl0) - if MediaContentType0 is not None and "image" in MediaContentType0: - assert MediaUrl0 is not None - twilio_client.handle_image(From, MediaUrl0) elif Body is not None: twilio_client.handle_message(From, Body)