Add pyupgrade pre-commit hook + modernize python code (#2611)
This commit is contained in:
@@ -38,7 +38,7 @@ class LocalStorage(BaseStorage):
|
||||
if not file_path.exists():
|
||||
return []
|
||||
try:
|
||||
with open(file_path, "r") as f:
|
||||
with open(file_path) as f:
|
||||
return [line.strip() for line in f.readlines() if line.strip()]
|
||||
except Exception:
|
||||
return []
|
||||
|
||||
Reference in New Issue
Block a user