From 54422f025953a5fad3829e1fb7bb1d57b21a819e Mon Sep 17 00:00:00 2001 From: Joshi425 Date: Sat, 9 May 2020 20:11:44 +0200 Subject: [PATCH] fix 1.15 Support --- minecraft_exporter.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/minecraft_exporter.py b/minecraft_exporter.py index 783270a..581fb17 100644 --- a/minecraft_exporter.py +++ b/minecraft_exporter.py @@ -234,7 +234,7 @@ class MinecraftCollector(object): elif stat == "questsFinished": player_quests_finished.add_sample('player_quests_finished',value=value,labels={'player':name}) - if data["stats"]: # Minecraft > 1.15 + if "stats" in data: # Minecraft > 1.15 for block, value in data["stats"]["minecraft:crafted"].items(): blocks_crafted.add_sample('blocks_crafted',value=value,labels={'player':name,'block':block}) for block, value in data["stats"]["minecraft:mined"].items():