Fix initializing OrgNode level to string to parse org files

- Parsed `level` argument passed to OrgNode during init is expected to
  be a string, not an integer
- This was resulting in app failure only when parsing org files with
  no headings, like in issue #83, as level is set to string of `*`s
  the moment a heading is found in the current file
This commit is contained in:
Debanjum Singh Solanky
2022-09-10 13:11:58 +03:00
parent d835467f2c
commit d6bd7bf3e1
2 changed files with 25 additions and 3 deletions

View File

@@ -61,7 +61,7 @@ def makelist(filename):
todos = { "TODO": "", "WAITING": "", "ACTIVE": "",
"DONE": "", "CANCELLED": "", "FAILED": ""} # populated from #+SEQ_TODO line
level = 0
level = ""
heading = ""
bodytext = ""
tags = set() # set of all tags in headline