Fix user import issues

This commit is contained in:
amcmanu3 2022-06-13 14:45:01 -04:00
parent 0ffe6801d8
commit 4019f0365e

View File

@ -38,9 +38,12 @@ class Import3:
# If there is only one user to import json needs to call the data differently
if isinstance(json_data, list):
for user in json_data:
if not str(user["username"]).lower() == "admin":
HelperUsers.add_rawpass_user(user["username"], user["password"])
Console.info(f"Imported user {user['username']} from Crafty 3")
logger.info(f"Imported user {user['username']} from Crafty 3")
else:
logger.info("Cannot create duplicate Admin account...skipping.")
else:
Console.info(
"There is only one user detected. "