Fixed UP015 (redundant-open-modes): Unnecessary mode argument

This commit is contained in:
Teal Dulcet
2025-06-20 02:40:00 -07:00
parent 498e92dc95
commit ee11f3849b
2 changed files with 3 additions and 3 deletions
+2 -2
View File
@@ -124,7 +124,7 @@ def generate_documentation():
""")
parser = Source.parser()
with open("setup/start.sh", "r", encoding="utf-8") as start_file:
with open("setup/start.sh", encoding="utf-8") as start_file:
for line in start_file:
try:
fn = parser.parse_string(line).filename()
@@ -401,7 +401,7 @@ class BashScript(Grammar):
@staticmethod
def parse(fn):
if fn in ("setup/functions.sh", "/etc/mailinabox.conf"): return ""
with open(fn, "r", encoding="utf-8") as f:
with open(fn, encoding="utf-8") as f:
string = f.read()
# tokenize