Skip to content

Commit

Permalink
Mark AutodeferMode.ON as the default
Browse files Browse the repository at this point in the history
  • Loading branch information
hypergonial committed Dec 30, 2023
1 parent 71114a6 commit 8ea7142
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion docs/guides/interactions.md
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ await context.respond("I'm secret!", flags=hikari.MessageFlag.EPHEMERAL)
You'd expect the interaction in the above command to time out after 3 seconds, and the call to [`Context.respond()`][arc.context.base.Context.respond] to fail, however `arc`, by default, after 2 seconds of not providing an initial response, defers the interaction for you to keep the interaction alive, thus the command succeeds. This default behaviour may however be undesirable if you want to, for example, make the initial response be ephemeral, or have tighter control over how the initial response is created. For this reason, `arc` provides 3 seperate configurations for autodeferring through the [`AutodeferMode`][arc.context.base.AutodeferMode] enum.

- `AutodeferMode.OFF` - Autodeferring is completely turned off. If you fail to respond within 3 seconds, the interaction fails.
- `AutodeferMode.ON` - The interaction will be deferred after 2 seconds if you did not create an initial response by then. **The defer will not be ephemeral**.
- `AutodeferMode.ON` (Default) - The interaction will be deferred after 2 seconds if you did not create an initial response by then. **The defer will not be ephemeral**.
- `AutodeferMode.EPHEMERAL` - The interaction will be deferred after 2 seconds if you did not create an initial response by then. **The defer will be ephemeral**.

This can be passed to the command decorator's `autodefer=` keyword argument:
Expand Down

0 comments on commit 8ea7142

Please sign in to comment.