returning different things to a run method

I was wondering if it is possible to return for example, a string to a chatinputrun method and have sapphire know to just reply to the interaction with that string or for example return an object with an embeds property with valid embed json same deal
4 Replies
alqm
alqmOP2d ago
so instead of return interaction.reply('x'); its return 'x'; or instead of return interaction.reply({ embeds: [{ description: 'x' }] }); its return { embed: [ { description: 'x' } ] }; like can i modify how sapphire handles replies on my side without modifying the underlying library code
čamdžić
čamdžić2d ago
I don’t think that’s possible There is ChatInputCommandSuccess but I don’t think that’s what you are looking for
Favna
Favna16h ago
Not possible and won't be implemented. For 2 lines of code of laziness by users like yourself it introduced a dozen difficulties for the library by the mere existence of assumptions.
alqm
alqmOP15h ago
well thought out response to call your users lazy but thanks for the response anyways

Did you find this page helpful?