Skip to content

Commit ee64a0b

Browse files
committed
Don't use str as argument name
1 parent cb99e59 commit ee64a0b

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

app/pandoc.py

+5-5
Original file line numberDiff line numberDiff line change
@@ -36,10 +36,10 @@
3636
def task_lists_to_markdown(task_lists: list[TaskList]) -> str:
3737
"""Parses Task Lists to a Pandoc markdown"""
3838

39-
def str_to_pandoc(str: str):
39+
def text_to_pandoc(text: str):
4040
elems = []
41-
for s in str.split():
42-
elems.append(Str(s))
41+
for word in text.split():
42+
elems.append(Str(word))
4343
elems.append(Space())
4444
return elems[:-1]
4545

@@ -54,7 +54,7 @@ def task_to_pandoc(task: Task, parent_contains_notes: bool):
5454
pandocTask = []
5555

5656
task_sign = "☒" if task.completed() else "☐"
57-
task_title = [Str(task_sign), Space()] + str_to_pandoc(task.title)
57+
task_title = [Str(task_sign), Space()] + text_to_pandoc(task.title)
5858

5959
if parent_contains_notes:
6060
pandocTask.append(Para(task_title))
@@ -83,7 +83,7 @@ def task_to_pandoc(task: Task, parent_contains_notes: bool):
8383
]
8484

8585
for task_list in task_lists:
86-
content.append(Header(2, EMPTY_ATTRS, str_to_pandoc(task_list.title)))
86+
content.append(Header(2, EMPTY_ATTRS, text_to_pandoc(task_list.title)))
8787
content.append(
8888
OrderedList(ORDERED_FIRST_ELEM, tasks_to_pandoc(task_list.tasks))
8989
)

0 commit comments

Comments
 (0)