Skip to content

Commit

Permalink
Only set rdt config if it was passed in intent
Browse files Browse the repository at this point in the history
  • Loading branch information
vincent-karuri committed Oct 21, 2020
1 parent 6d6571a commit ff98f23
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,10 @@ protected void onCreate(Bundle savedInstanceState) {

try {
// Extract config json obj
mImageQualityView.setRdtJsonConfig(new JSONObject(b.getString(RDT_JSON_CONFIG)));
String rdtConfig = b.getString(RDT_JSON_CONFIG, null);
if (rdtConfig != null) {
mImageQualityView.setRdtJsonConfig(new JSONObject(rdtConfig));
}
} catch (JSONException e) {
e.printStackTrace();
}
Expand Down

0 comments on commit ff98f23

Please sign in to comment.