discord-api-docs icon indicating copy to clipboard operation
discord-api-docs copied to clipboard

Empty slash responses break messages

Open VelvetToroyashi opened this issue 1 month ago • 0 comments

Description

Providing an empty interaction response produces an empty message in a broken state. The pseudo-message of "Sending command" is updated to have no content, which causes some interesting behavior in the client. This behavior is exhibited both with HTTP interactions (returning the data as the response) and gateway interactions (POSTing to /callback). For the latter, Discord does return an error to the bot, but not the client.

Steps to Reproduce

Respond to an interaction with {"type":4}

Expected Behavior

The client/API updates the message to the usual "This interaction failed" message.

Current Behavior

The slash response is a greyed out message with no content, causing messages to overlap. Pressing up arrow (usually, re-run lash slash command) invokes the command as a slash command regardless of type (I can open another issue about that, if wanted).

Screenshots/Videos

image

Client and System Information

Tested on both stable 291963 (cd5f991) (Web client) and canary 292610 (6e0fcca) (Linux client)

VelvetToroyashi avatar May 10 '24 23:05 VelvetToroyashi