Revert "Remove reset session button."

This reverts commit f24020e7b7.
This commit is contained in:
Greyson Parrelli
2021-01-16 18:42:48 -05:00
parent 3e43963f67
commit 4571151e3c
4 changed files with 56 additions and 1 deletions

View File

@@ -278,6 +278,20 @@ public class SignalServiceMessageSender {
sendMessage(localAddress, Optional.<UnidentifiedAccess>absent(), timestamp, syncMessage, false, null);
}
// TODO [greyson][session] Delete this when we delete the button
if (message.isEndSession()) {
if (recipient.getUuid().isPresent()) {
store.deleteAllSessions(recipient.getUuid().get().toString());
}
if (recipient.getNumber().isPresent()) {
store.deleteAllSessions(recipient.getNumber().get());
}
if (eventListener.isPresent()) {
eventListener.get().onSecurityEvent(recipient);
}
}
return result;
}