mirror of
https://github.com/PaiGramTeam/PaiGram.git
synced 2024-11-22 07:07:46 +00:00
🐛 Fix to get the question id
梅开二度
This commit is contained in:
parent
6e8f29786e
commit
884afa3087
@ -36,8 +36,8 @@ class QuizPlugin(Plugin, BasePlugin):
|
||||
return None
|
||||
if len(question_id_list) == 0:
|
||||
return None
|
||||
index = random.choice(question_id_list) # nosec
|
||||
question = await self.quiz_service.get_question(question_id_list[index])
|
||||
question_id = random.choice(question_id_list) # nosec
|
||||
question = await self.quiz_service.get_question(question_id)
|
||||
_options = []
|
||||
correct_option = None
|
||||
for answer in question.answers:
|
||||
|
Loading…
Reference in New Issue
Block a user