Ver Fonte

[videogames] Fix index error with IGDB lookups

Colin Powell há 1 ano atrás
pai
commit
302ddf6650
1 ficheiros alterados com 1 adições e 1 exclusões
  1. 1 1
      vrobbler/apps/videogames/igdb.py

+ 1 - 1
vrobbler/apps/videogames/igdb.py

@@ -52,7 +52,7 @@ def lookup_game_id_from_gdb(name: str) -> str:
         logger.warn(f"Search of game on IGDB failed for name {name}")
         return ""
 
-    return results[0]["game"]
+    return results[0].get("game", "")
 
 
 def lookup_game_from_igdb(name_or_igdb_id: str) -> Dict: