mirror of
https://github.com/jrnl-org/jrnl.git
synced 2025-06-29 22:16:13 +02:00
Create folder if config ends with (back)slash (#1492)
* Check config if FolderJournal and treat as so * Add test for end of path is slash * Code format correction * Requested changes PR 1482 * Add info to doc about path of folder. * Small addition to doc about folder journal
This commit is contained in:
parent
1c35c6951d
commit
e758986985
5 changed files with 38 additions and 3 deletions
|
@ -434,6 +434,10 @@ def open_journal(journal_name, config, legacy=False):
|
|||
if not config["encrypt"]:
|
||||
if legacy:
|
||||
return LegacyJournal(journal_name, **config).open()
|
||||
if config["journal"].endswith(os.sep):
|
||||
from . import FolderJournal
|
||||
|
||||
return FolderJournal.Folder(journal_name, **config).open()
|
||||
return PlainJournal(journal_name, **config).open()
|
||||
|
||||
from . import EncryptedJournal
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue