Removed unnecessary with clause
This commit is contained in:
parent
a77418cbdc
commit
871b6cc839
@ -105,8 +105,7 @@ def read_file(output_path: str) -> [str]:
|
|||||||
|
|
||||||
Reads file from a specich path and returns it as a list
|
Reads file from a specich path and returns it as a list
|
||||||
"""
|
"""
|
||||||
with open(output_path, 'r') as file:
|
return [row.strip() for row in open(output_path, 'r').readlines() if row]
|
||||||
return [row.strip() for row in file.readlines() if row]
|
|
||||||
|
|
||||||
def is_starting_section(
|
def is_starting_section(
|
||||||
row: str,
|
row: str,
|
||||||
@ -237,4 +236,3 @@ def main():
|
|||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
# execute only if run as a script
|
# execute only if run as a script
|
||||||
main()
|
main()
|
||||||
|
|
Loading…
Reference in New Issue
Block a user