Skip to content

Commit

Permalink
Keep first dispute chat msg when clearing sensitive data.
Browse files Browse the repository at this point in the history
  • Loading branch information
jmacxx committed Feb 24, 2022
1 parent 70752a1 commit f430243
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions core/src/main/java/bisq/core/support/dispute/Dispute.java
Original file line number Diff line number Diff line change
Expand Up @@ -352,8 +352,10 @@ public void addAndPersistChatMessage(ChatMessage chatMessage) {
}

public boolean removeAllChatMessages() {
if (chatMessages.size() > 0) {
chatMessages.clear();
if (chatMessages.size() > 1) {
// removes all chat except the initial guidelines message.
String firstMessageUid = chatMessages.get(0).getUid();
chatMessages.removeIf((msg) -> !msg.getUid().equals(firstMessageUid));
return true;
}
return false;
Expand Down

0 comments on commit f430243

Please sign in to comment.