mapNotNull

fun <T> JSONArray.mapNotNull(block: (JSONObject) -> T?): List<T>

Maps a JSONArray by the block function excluding null values