mirror of
https://github.com/jrnl-org/jrnl.git
synced 2025-05-13 09:58:31 +02:00
rename function, fix some linting issues
This commit is contained in:
parent
c52dcfef5a
commit
bb1f263d6c
3 changed files with 6 additions and 6 deletions
|
@ -5,12 +5,11 @@ import datetime
|
|||
import logging
|
||||
import os
|
||||
import re
|
||||
from types import ModuleType
|
||||
|
||||
from jrnl import EncryptedJournal
|
||||
from jrnl import Entry
|
||||
from jrnl import time
|
||||
from jrnl.encryption import BaseEncryption
|
||||
from jrnl.encryption import determine_encryption_type
|
||||
from jrnl.encryption import determine_encryption_method
|
||||
from jrnl.messages import Message
|
||||
from jrnl.messages import MsgStyle
|
||||
from jrnl.messages import MsgText
|
||||
|
@ -82,7 +81,7 @@ class Journal:
|
|||
self.sort()
|
||||
|
||||
def _get_encryption_method(self):
|
||||
self._encryption_method = determine_encryption_type(self.config["encrypt"])(
|
||||
self._encryption_method = determine_encryption_method(self.config["encrypt"])(
|
||||
self.config
|
||||
)
|
||||
|
||||
|
|
|
@ -3,9 +3,9 @@
|
|||
from jrnl.encryption.NoEncryption import NoEncryption
|
||||
|
||||
|
||||
def determine_encryption_type(config):
|
||||
def determine_encryption_method(config):
|
||||
encryption_method = NoEncryption
|
||||
if config is True:
|
||||
if config is True or config == "jrnlv2":
|
||||
# Default encryption method
|
||||
from jrnl.encryption.Jrnlv2Encryption import Jrnlv2Encryption
|
||||
|
||||
|
|
|
@ -4,6 +4,7 @@
|
|||
import os
|
||||
|
||||
from jrnl import Journal
|
||||
from jrnl import PlainJournal
|
||||
from jrnl import __version__
|
||||
from jrnl.config import is_config_json
|
||||
from jrnl.config import load_config
|
||||
|
|
Loading…
Add table
Reference in a new issue