eric6/Utilities/crypto/__init__.py

changeset 8235
78e6d29eb773
parent 8143
2c730d5fd177
child 8273
698ae46f40a4
--- a/eric6/Utilities/crypto/__init__.py	Tue Apr 13 18:02:59 2021 +0200
+++ b/eric6/Utilities/crypto/__init__.py	Tue Apr 13 19:59:17 2021 +0200
@@ -253,11 +253,7 @@
     @param newPassword new password to be used (string)
     """
     global MasterPassword
-    
-    if newPassword == "":
-        MasterPassword = None
-    else:
-        MasterPassword = pwEncode(newPassword)
+    MasterPassword = pwEncode(newPassword) if newPassword else None
 
 
 def dataEncrypt(data, password, keyLength=32, hashIterations=10000):

eric ide

mercurial