From ed4095a6ef4461bc1c6a3c9584010b8ad2388eb2 Mon Sep 17 00:00:00 2001 From: Austin Huang Date: Sun, 4 Oct 2020 10:30:52 -0400 Subject: [PATCH] more fb messenger stuff --- .../main/java/awais/instagrabber/utils/ResponseBodyUtils.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/src/main/java/awais/instagrabber/utils/ResponseBodyUtils.java b/app/src/main/java/awais/instagrabber/utils/ResponseBodyUtils.java index c21b77f9..2ab4f741 100644 --- a/app/src/main/java/awais/instagrabber/utils/ResponseBodyUtils.java +++ b/app/src/main/java/awais/instagrabber/utils/ResponseBodyUtils.java @@ -257,8 +257,8 @@ public final class ResponseBodyUtils { final JSONArray users = data.getJSONArray("users"); final int usersLen = users.length(); - final JSONArray leftusers = data.getJSONArray("left_users"); - final int leftusersLen = leftusers.length(); + final JSONArray leftusers = data.optJSONArray("left_users"); + final int leftusersLen = leftusers == null ? 0 : leftusers.length(); final JSONArray admins = data.getJSONArray("admin_user_ids"); final int adminsLen = admins.length();