Skip to content

Commit a0325e9

Browse files
committed
Use context manager for open
1 parent 56bafd9 commit a0325e9

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

setup.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,8 @@ def get_version():
1111

1212

1313
def read(filename):
14-
return open(os.path.join(os.path.dirname(__file__), filename)).read()
14+
with open(os.path.join(os.path.dirname(__file__), filename)) as f:
15+
return f.read()
1516

1617

1718
setup(

0 commit comments

Comments
 (0)