Aircraft Overviewer
Aircraft Overviewer
DIAdiscord.js - Imagine an app
Created by treble/luna on 6/21/2023 in #djs-questions
Weird bug (?) with typescript and SlashCommandBuilders
Changing the position of #setDMPermissions() "solved" it before because the type check you had in place was for a SlashCommandBuilder and it seems that setting the DM permissions after a slash command option removes the omitted generic from the instance. As Syjalo already pointed out, adding a generic to account for this in your check removes the issue all together as it allows for this omitted generic to pass the type check as well as a regular SlashCommandBuilder instance :P
8 replies