We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 3664a3b commit f80825fCopy full SHA for f80825f
1 file changed
main.py
@@ -36,7 +36,7 @@ def update_records(issue, issue_number=None):
36
issue_labels = ["`" + label["name"] + "`" for label in issue["labels"]]
37
issue_link = issue["html_url"]
38
39
- with open("DailyLC.md", "r+") as file:
+ with open("DailyLC.md", "r") as file:
40
lines = file.readlines()
41
42
table_start_index = None
@@ -56,8 +56,9 @@ def update_records(issue, issue_number=None):
56
else:
57
lines.insert(table_start_index, new_line)
58
59
- file.seek(0)
+ with open('DailyLC.md', 'w') as file:
60
file.writelines(lines)
61
+ file.close()
62
63
return "Successfully updated Records of DailyLC.md"
64
0 commit comments