Save this assignment until it's needed.

master
voussoir 2018-12-21 23:44:50 -08:00
parent d736c81100
commit c6c6158062
1 changed files with 1 additions and 1 deletions

View File

@ -1414,11 +1414,11 @@ class PhotoDB(
thing_table = thing_map['table']
thing_class = thing_map['class']
thing_cache = self.caches[thing_type]
thing_index = constants.SQL_INDEX[thing_table]
if isinstance(db_row, dict):
thing_id = db_row['id']
else:
thing_index = constants.SQL_INDEX[thing_table]
thing_id = db_row[thing_index['id']]
try: