Fix models error when trying to edit admin username

This commit is contained in:
Andrew 2021-08-22 17:42:12 -04:00
parent 000c764ca3
commit d83fd73755

View File

@ -576,7 +576,7 @@ class db_shortcuts:
elif base_data[key] != user_data[key]:
up_data[key] = user_data[key]
up_data['last_update'] = helper.get_time_as_string()
logger.debug("user: {} +role:{} -role:{} +server:{} -server{}".format(user_data, added_roles, removed_roles))
logger.debug("user: {} +role:{} -role:{}".format(user_data, added_roles, removed_roles))
with database.atomic():
for role in added_roles:
User_Roles.get_or_create(user_id=user_id, role_id=role)