diff --git a/discord/ui/view.py b/discord/ui/view.py index 0f7087696..448a9e863 100644 --- a/discord/ui/view.py +++ b/discord/ui/view.py @@ -413,15 +413,15 @@ class View: async def _scheduled_task(self, item: Item, interaction: Interaction): try: - if self.timeout: - self.__timeout_expiry = time.monotonic() + self.timeout - item._refresh_state(interaction.data) # type: ignore allow = await self.interaction_check(interaction) if not allow: return + if self.timeout: + self.__timeout_expiry = time.monotonic() + self.timeout + await item.callback(interaction) except Exception as e: return await self.on_error(interaction, e, item)