FS updates and corrections
This commit is contained in:
@@ -207,7 +207,11 @@ class Thread(ChatBaseModel):
|
||||
|
||||
@property
|
||||
def initiator_message(self):
|
||||
return self.messages[0] # TODO check if this needs sorting
|
||||
try:
|
||||
return self.messages[0] # TODO check if this needs sorting
|
||||
except IndexError:
|
||||
logger.warning(f"Thread {self} is empty. How can that be?")
|
||||
return None
|
||||
|
||||
@property
|
||||
def message_count(self):
|
||||
@@ -222,6 +226,9 @@ class Thread(ChatBaseModel):
|
||||
@property
|
||||
def is_fully_processed(self) -> bool:
|
||||
init_message = self.initiator_message
|
||||
if init_message is None:
|
||||
return False
|
||||
|
||||
if init_message.is_processed_override:
|
||||
return True
|
||||
# this override is set for instance, when no url was sent at all. Then set this thread to be ignored
|
||||
|
||||
Reference in New Issue
Block a user