hide verify snackbar when otr session is ended. fixed npe
This commit is contained in:
parent
9ddd2f195e
commit
542cbef53b
|
@ -291,6 +291,9 @@ public class Conversation extends AbstractEntity {
|
||||||
public String getOtrFingerprint() {
|
public String getOtrFingerprint() {
|
||||||
if (this.otrFingerprint == null) {
|
if (this.otrFingerprint == null) {
|
||||||
try {
|
try {
|
||||||
|
if (getOtrSession()== null) {
|
||||||
|
return "";
|
||||||
|
}
|
||||||
DSAPublicKey remotePubKey = (DSAPublicKey) getOtrSession()
|
DSAPublicKey remotePubKey = (DSAPublicKey) getOtrSession()
|
||||||
.getRemotePublicKey();
|
.getRemotePublicKey();
|
||||||
StringBuilder builder = new StringBuilder(
|
StringBuilder builder = new StringBuilder(
|
||||||
|
|
|
@ -80,6 +80,7 @@ public class MessageParser extends AbstractParser implements
|
||||||
mXmppConnectionService.onOtrSessionEstablished(conversation);
|
mXmppConnectionService.onOtrSessionEstablished(conversation);
|
||||||
} else if ((before != after) && (after == SessionStatus.FINISHED)) {
|
} else if ((before != after) && (after == SessionStatus.FINISHED)) {
|
||||||
conversation.resetOtrSession();
|
conversation.resetOtrSession();
|
||||||
|
mXmppConnectionService.updateConversationUi();
|
||||||
}
|
}
|
||||||
if ((body == null) || (body.isEmpty())) {
|
if ((body == null) || (body.isEmpty())) {
|
||||||
return null;
|
return null;
|
||||||
|
|
Loading…
Reference in a new issue