Skip to content

Commit

Permalink
Add has message check for chat history
Browse files Browse the repository at this point in the history
  • Loading branch information
gabber235 committed Oct 8, 2024
1 parent 7af77e5 commit 0277eab
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,10 @@ class ChatHistory {
}
}

fun hasMessage(message: Component): Boolean {
return messages.any { it.message == message }
}

fun clear() {
messages.clear()
}
Expand Down

0 comments on commit 0277eab

Please sign in to comment.