mirror of
https://iceshrimp.dev/limepotato/jormungandr-bite.git
synced 2025-03-04 07:18:50 -07:00
[API] Fix bug
This commit is contained in:
parent
0c0f43c55b
commit
97c9935c68
1 changed files with 1 additions and 1 deletions
|
@ -33,7 +33,7 @@ module.exports = (params, user) => new Promise(async (res, rej) => {
|
|||
|
||||
// Get 'choice' parameter
|
||||
const [choice, choiceError] =
|
||||
$(params.choice).string()
|
||||
$(params.choice).number()
|
||||
.pipe(c => post.poll.choices.some(x => x.id == c))
|
||||
.$;
|
||||
if (choiceError) return rej('invalid choice param');
|
||||
|
|
Loading…
Add table
Reference in a new issue