null check otr fingerprint before display

This commit is contained in:
Daniel Gultsch 2015-07-11 21:23:58 +02:00
parent c4876fab1b
commit 5dd83a5fe6
1 changed files with 3 additions and 1 deletions

View File

@ -91,7 +91,9 @@ public final class CryptoHelper {
}
public static String prettifyFingerprint(String fingerprint) {
if (fingerprint.length() < 40) {
if (fingerprint==null) {
return "";
} else if (fingerprint.length() < 40) {
return fingerprint;
}
StringBuilder builder = new StringBuilder(fingerprint);