Skip to content

Commit

Permalink
#1262 - crash fix
Browse files Browse the repository at this point in the history
  • Loading branch information
budowski committed Apr 29, 2023
1 parent c68166e commit bd62d70
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
4 changes: 2 additions & 2 deletions iNaturalist/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
xmlns:tools="http://schemas.android.com/tools"
package="org.inaturalist.android"
android:installLocation="auto"
android:versionCode="569"
android:versionName="1.28.16">
android:versionCode="570"
android:versionName="1.28.17">

<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6277,7 +6277,10 @@ public void syncJson(JSONArray json, boolean isUser) {

// Save project field values
Hashtable<Integer, ProjectFieldValue> fields = new Hashtable<Integer, ProjectFieldValue>();
JSONArray jsonFields = o.getJSONArray(o.has("ofvs") ? "ofvs" : "observation_field_values").getJSONArray();
SerializableJSONArray arr = o.getJSONArray(o.has("ofvs") ? "ofvs" : "observation_field_values");
if (arr == null) continue;

JSONArray jsonFields = arr.getJSONArray();

for (int j = 0; j < jsonFields.length(); j++) {
BetterJSONObject field = new BetterJSONObject(jsonFields.getJSONObject(j));
Expand Down

0 comments on commit bd62d70

Please sign in to comment.