mirror of
https://github.com/codespell-project/codespell.git
synced 2025-05-17 15:36:17 +08:00
fix condition for closing file
This commit is contained in:
@ -132,7 +132,7 @@ def parse_file(filename, colors):
|
||||
print('Error decoding file: %s' % filename, file=sys.stderr)
|
||||
return
|
||||
finally:
|
||||
if filename == '-':
|
||||
if filename != '-':
|
||||
f.close()
|
||||
|
||||
i = 1
|
||||
|
Reference in New Issue
Block a user