Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
…ss-Android into feature/material-appcompat
  • Loading branch information
nbradbury committed Nov 21, 2014
2 parents 7384a6d + 4938e39 commit 2624b92
Showing 1 changed file with 0 additions and 21 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -232,25 +232,4 @@ public static JSONObject getJSONChild(final JSONObject jsonParent, final String
}
return jsonChild;
}

// Returns a copy of the passed JSONObject
@SuppressWarnings("unchecked")
public static JSONObject copyJSONObject(JSONObject object) {
JSONObject objectCopy = new JSONObject();

if (object == null) return objectCopy;

Iterator<String> iterator = object.keys();
while (iterator.hasNext()) {
try {
String key = iterator.next();
Object value = object.get(key);
objectCopy.put(key, value);
} catch (JSONException e) {
AppLog.e(T.UTILS, e);
}
}

return objectCopy;
}
}

0 comments on commit 2624b92

Please sign in to comment.