update ui related files & functions
This commit is contained in:
@@ -71,7 +71,7 @@ class Ui_Dialog(object):
|
||||
hashed_password = hashlib.sha256(
|
||||
password.encode()
|
||||
).hexdigest()
|
||||
if len(db.get_users()) == 0:
|
||||
if len(db.getUsers()) == 0:
|
||||
AdminCommands().create_admin()
|
||||
self.lresult = 1 # Indicate successful login
|
||||
self.lusername = username
|
||||
@@ -80,7 +80,6 @@ class Ui_Dialog(object):
|
||||
self.lresult = 1 # Indicate successful login
|
||||
self.lusername = username
|
||||
self.dialog.accept()
|
||||
db.close()
|
||||
else:
|
||||
# Credentials are invalid, display a warning
|
||||
if username == "" or password == "":
|
||||
|
||||
Reference in New Issue
Block a user