aboutsummaryrefslogtreecommitdiff
path: root/main.py
diff options
context:
space:
mode:
authorhuker667 <huker@tuta.io>2026-07-09 16:23:48 +0300
committerhuker667 <huker@tuta.io>2026-07-09 16:23:48 +0300
commit28c60a94f3bf2998f07bc7089d5266d510835613 (patch)
treef4991d6751e2668d55d4356441b0057aca765301 /main.py
parentee5a6bdcc379527c537e23b689816555832fda5c (diff)
downloaduzbekgpt-28c60a94f3bf2998f07bc7089d5266d510835613.tar.gz
uzbekgpt-28c60a94f3bf2998f07bc7089d5266d510835613.tar.bz2
uzbekgpt-28c60a94f3bf2998f07bc7089d5266d510835613.zip
add multipoll support
Diffstat (limited to 'main.py')
-rw-r--r--main.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/main.py b/main.py
index 14c1ba2..e54c349 100644
--- a/main.py
+++ b/main.py
@@ -343,7 +343,7 @@ async def guest_middleware(handler, event, data):
correct_option = options[0]
correct_option_id = None
is_anon = True
- allow_multiple_answers = False
+ allows_multiple_answers = False
if event.guest_message:
mid = user_id
@@ -359,10 +359,10 @@ async def guest_middleware(handler, event, data):
correct_option_id = options.index(correct_option)
elif poll_type == "poll":
poll_type = "regular"
- allow_multiple_answers = False
+ allows_multiple_answers = False
elif poll_type == "multipoll":
poll_type = "regular"
- allow_multiple_answers = True
+ allows_multiple_answers = True
else:
poll_type = "regular"
@@ -374,6 +374,7 @@ async def guest_middleware(handler, event, data):
options=options,
is_anonymous=is_anon,
poll_type=poll_type,
+ allows_multiple_answers=allows_multiple_answers,
correct_option_id=correct_option_id,
user_id=mid
)