Skip to content

Commit 2b9e3fd

Browse files
committed
fix: readd missing attr to component context
1 parent ce608a5 commit 2b9e3fd

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

interactions/models/internal/context.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -628,6 +628,8 @@ class ComponentContext(InteractionContext, ModalMixin):
628628
"""The custom_id of the component."""
629629
component_type: int
630630
"""The type of the component."""
631+
defer_edit_origin: bool
632+
"""Whether you have deferred the interaction and are editing the original response."""
631633

632634
@classmethod
633635
def from_dict(cls, client: "interactions.Client", payload: dict) -> Self:
@@ -637,6 +639,7 @@ def from_dict(cls, client: "interactions.Client", payload: dict) -> Self:
637639
instance._command_id = instance.custom_id
638640
instance._command_name = instance.custom_id
639641
instance.component_type = payload["data"]["component_type"]
642+
instance.defer_edit_origin = False
640643

641644
searches = {
642645
"users": instance.component_type in (ComponentType.USER_SELECT, ComponentType.MENTIONABLE_SELECT),

0 commit comments

Comments
 (0)