diff options
Diffstat (limited to '')
-rw-r--r-- | src/de/gultsch/chat/entities/Account.java | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/de/gultsch/chat/entities/Account.java b/src/de/gultsch/chat/entities/Account.java index 3ffc75f9..c8f6d063 100644 --- a/src/de/gultsch/chat/entities/Account.java +++ b/src/de/gultsch/chat/entities/Account.java @@ -137,8 +137,13 @@ public class Account extends AbstractEntity{ return keys; } - public void setKey(String keyName, String keyValue) throws JSONException { - this.keys.put(keyName, keyValue); + public boolean setKey(String keyName, String keyValue) { + try { + this.keys.put(keyName, keyValue); + return true; + } catch (JSONException e) { + return false; + } } @Override |