Skip to content

Commit

Permalink
origin_interface getter fixed
Browse files Browse the repository at this point in the history
  • Loading branch information
pseusys committed Oct 23, 2024
1 parent bf45571 commit dba82d2
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions chatsky/core/context.py
Original file line number Diff line number Diff line change
Expand Up @@ -150,9 +150,10 @@ class Context(BaseModel):
@property
def origin_interface(self) -> Optional[str]:
if 1 in self.requests.keys():
return self.requests[1].origin_interface
else:
return None
origin = self.requests[1].origin
if origin is not None:
return origin.origin_interface
return None

@classmethod
def init(cls, start_label: AbsoluteNodeLabelInitTypes, id: Optional[Union[UUID, int, str]] = None):
Expand Down

0 comments on commit dba82d2

Please sign in to comment.