We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 365414d commit 5d89246Copy full SHA for 5d89246
1 file changed
lib/location.py
@@ -49,7 +49,7 @@ def add_coordinates(seatmap, cursor):
49
if not switches.get(table, []):
50
logging.debug("Table %s has no switches, ignoring", table)
51
continue
52
- c, scale = table_location(table, tables)
+ c, scale = table_location(table, tables, hall)
53
scales.append(scale)
54
table_coordinates[hall].append((table, c))
55
@@ -129,9 +129,9 @@ def switch_locations(t, n):
129
return locations
130
131
132
-def table_location(table, tables):
+def table_location(table, tables, hall):
133
seats = sorted(
134
- tables[get_hall_from_table_name(table)][table],
+ tables[hall][table],
135
key=lambda seat: int(seat['seat']))
136
logging.debug("First and last seat on %s is %s and %s",
137
table, seats[0]["seat"], seats[-1]["seat"])
0 commit comments