private List<PlayerStats> convertStatSummaries(JsonObject statSummariesObject, long summonerId) throws RiotApiException
	{
		try
		{
			//Check summoner IDs to make sure the server isn't crazy
			long rootSummonerId = statSummariesObject.getLong("summonerId");
			if(rootSummonerId != summonerId)
				throw new RiotApiException("Server returned invalid data: summoner ID mismatch");
			
			//Convert stat summaries list
			JsonArray sumsArray = statSummariesObject.getArray("playerStatSummaries");
			List<PlayerStats> sums = new ArrayList<>(sumsArray.size());
			for(int s = 0; s < sumsArray.size(); s++)
			{
				JsonObject sumObject = sumsArray.getObject(s);
				
				//Convert stats list
				Map<String, Integer> stats = convertAggregatedStats(sumObject.getObject("aggregatedStats"));
				
				//Create stat summary object
				PlayerStats sum = new PlayerStats(sumObject.getString("playerStatSummaryType"), sumObject.getLong("modifyDate"),
						sumObject.containsKey("wins") ? sumObject.getInt("wins") : 0,
						sumObject.containsKey("losses") ? sumObject.getInt("losses") : 0,
						stats);
				sums.add(sum);
			}
			return sums;
		}
		catch(JsonException e)
		{
			//Shouldn't happen since the JSON is already parsed
			System.err.println("JSON parse error");
			e.printStackTrace();
			return null;
		}
	}