mirror of
https://github.com/jrnl-org/jrnl.git
synced 2025-05-17 19:48:31 +02:00
Deprecate config.password
This commit is contained in:
parent
06f8dbe678
commit
36ec964d0c
2 changed files with 1 additions and 11 deletions
|
@ -67,15 +67,7 @@ class EncryptedJournal(Journal.Journal):
|
||||||
key = make_key(password)
|
key = make_key(password)
|
||||||
return _decrypt(journal_encrypted, key)
|
return _decrypt(journal_encrypted, key)
|
||||||
|
|
||||||
text = None
|
return util.get_password(keychain=self.name, validator=validate_password)
|
||||||
|
|
||||||
if 'password' in self.config:
|
|
||||||
text = validate_password(self.config['password'])
|
|
||||||
|
|
||||||
if text is None:
|
|
||||||
text = util.get_password(keychain=self.name, validator=validate_password)
|
|
||||||
|
|
||||||
return text
|
|
||||||
|
|
||||||
def _store(self, filename, text):
|
def _store(self, filename, text):
|
||||||
key = make_key(self.config['password'])
|
key = make_key(self.config['password'])
|
||||||
|
|
|
@ -119,8 +119,6 @@ def update_config(config, new_config, scope, force_local=False):
|
||||||
config.update(new_config)
|
config.update(new_config)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
def run(manual_args=None):
|
def run(manual_args=None):
|
||||||
args = parse_args(manual_args)
|
args = parse_args(manual_args)
|
||||||
args.text = [p.decode('utf-8') if util.PY2 and not isinstance(p, unicode) else p for p in args.text]
|
args.text = [p.decode('utf-8') if util.PY2 and not isinstance(p, unicode) else p for p in args.text]
|
||||||
|
|
Loading…
Add table
Reference in a new issue