diff options
author | cyBerta <cyberta@riseup.net> | 2019-05-20 21:30:48 +0200 |
---|---|---|
committer | cyBerta <cyberta@riseup.net> | 2019-05-20 21:30:48 +0200 |
commit | df991bb8a28ec8dd42d3ffcdcdc6cc0a6d1ce915 (patch) | |
tree | 932854a2713a8016a32ed358803a904ef935e553 /app/src/main/java | |
parent | 20206e5661ed3f786ed8b9bcaf1941be9b92a596 (diff) |
fix app crash if backend returns null instead of valid json response
Diffstat (limited to 'app/src/main/java')
-rw-r--r-- | app/src/main/java/se/leap/bitmaskclient/ProviderApiManagerBase.java | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/src/main/java/se/leap/bitmaskclient/ProviderApiManagerBase.java b/app/src/main/java/se/leap/bitmaskclient/ProviderApiManagerBase.java index 113b07f5..78ded399 100644 --- a/app/src/main/java/se/leap/bitmaskclient/ProviderApiManagerBase.java +++ b/app/src/main/java/se/leap/bitmaskclient/ProviderApiManagerBase.java @@ -559,7 +559,7 @@ public abstract class ProviderApiManagerBase { try { responseJson = new JSONObject(plain_response); - } catch (JSONException e) { + } catch (NullPointerException | JSONException e) { e.printStackTrace(); responseJson = getErrorMessageAsJson(error_json_exception_user_message); } |