Skip to content

Commit

Permalink
CustomServer: properly 'inherit' Archipelago from static_server_data (#…
Browse files Browse the repository at this point in the history
…3397)

This fixes a potential exception during room spin-up.
  • Loading branch information
black-sliver authored May 31, 2024
1 parent cc4e23a commit 9dd9ad3
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions WebHostLib/customserver.py
Original file line number Diff line number Diff line change
Expand Up @@ -106,9 +106,9 @@ def load(self, room_id: int):
static_gamespackage = self.gamespackage # this is shared across all rooms
static_item_name_groups = self.item_name_groups
static_location_name_groups = self.location_name_groups
self.gamespackage = {"Archipelago": static_gamespackage["Archipelago"]} # this may be modified by _load
self.item_name_groups = {}
self.location_name_groups = {}
self.gamespackage = {"Archipelago": static_gamespackage.get("Archipelago", {})} # this may be modified by _load
self.item_name_groups = {"Archipelago": static_item_name_groups.get("Archipelago", {})}
self.location_name_groups = {"Archipelago": static_location_name_groups.get("Archipelago", {})}

for game in list(multidata.get("datapackage", {})):
game_data = multidata["datapackage"][game]
Expand Down

0 comments on commit 9dd9ad3

Please sign in to comment.