GitSparTV / discordia-slash

Discordia application commands extension
MIT License
38 stars 13 forks source link

Command with no parameters errors #5

Closed checkraisefold closed 1 year ago

checkraisefold commented 3 years ago

https://github.com/GitSparTV/discordia-slash/blob/bb362159a17244c67d91ca47ad09dfb6d73a52af/Application.lua#L49

data.options is optional according to the interaction data structure spec https://discord.com/developers/docs/interactions/receiving-and-responding#interaction-object-interaction-data-structure

Uncaught Error: ...uff/ACCOUNT TRACKER/deps/discordia-slash/Application.lua:26: bad argument #1 to 'ipairs' (table expected, got nil)
stack traceback:
        [C]: in function 'ipairs'
        ...uff/ACCOUNT TRACKER/deps/discordia-slash/Application.lua:26: in function 'makeParams'
        ...uff/ACCOUNT TRACKER/deps/discordia-slash/Application.lua:48: in function <...uff/ACCOUNT TRACKER/deps/discordia-slash/Application.lua:42>
checkraisefold commented 3 years ago

this is because the package on lit is outdated

GitSparTV commented 3 years ago

Fuck lit

Yaumama commented 2 years ago

use the git repo