Remove list(dict.keys()) --> dict.keys() and list(dict.values()) --> dict.values()

This commit is contained in:
JonnyWong16 2020-04-01 15:31:15 -07:00
parent f4eff8a8c5
commit e26182c96e
7 changed files with 15 additions and 15 deletions

View file

@ -202,7 +202,7 @@ class MonitorDatabase(object):
trans_type = 'update'
changes_before = self.connection.total_changes
gen_params = lambda my_dict: [x + " = ?" for x in list(my_dict.keys())]
gen_params = lambda my_dict: [x + " = ?" for x in my_dict]
update_query = "UPDATE " + table_name + " SET " + ", ".join(gen_params(value_dict)) + \
" WHERE " + " AND ".join(gen_params(key_dict))