From 9d71313a0c2b2dc369a5974f4733204f22e89998 Mon Sep 17 00:00:00 2001 From: AsamK Date: Mon, 6 Jul 2015 10:47:43 +0200 Subject: [PATCH] Load json even if signalingKey is missing Is the case when the account is registered, but not verified --- src/main/java/cli/Manager.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/main/java/cli/Manager.java b/src/main/java/cli/Manager.java index 1e7f0226..ff2178b4 100644 --- a/src/main/java/cli/Manager.java +++ b/src/main/java/cli/Manager.java @@ -81,7 +81,9 @@ public class Manager { JSONObject in = new JSONObject(IOUtils.toString(new FileInputStream(getFileName()))); username = in.getString("username"); password = in.getString("password"); - signalingKey = in.getString("signalingKey"); + if (in.has("signalingKey")) { + signalingKey = in.getString("signalingKey"); + } axolotlStore = new JsonAxolotlStore(in.getJSONObject("axolotlStore")); registered = in.getBoolean("registered"); accountManager = new TextSecureAccountManager(URL, TRUST_STORE, username, password);