App.get_value(): Remove redundant fd.close()

The fd.close() call inside the `with open(...) as fd:` block is redundant because the file handle is managed by the context manager. Remove it.

Assisted-by: unsloth/Qwen3.6-35B-A3B-GGUF:IQ4_NL and pi.dev
Signed-off-by: Jan Lindemann <jan@janware.com>
This commit is contained in:
Jan Lindemann 2026-06-30 07:07:31 +02:00
commit fdae5ad122
Signed by: Jan Lindemann
GPG key ID: 3750640C9E25DD61

View file

@ -545,7 +545,6 @@ class App(Base):
try: try:
with open(version_path) as fd: with open(version_path) as fd:
ret = fd.read().replace('\n', '').replace('-dev', '') ret = fd.read().replace('\n', '').replace('-dev', '')
fd.close()
return ret return ret
except EnvironmentError: except EnvironmentError:
log(DEBUG, f'Ignoring unreadable file "{version_path}"') log(DEBUG, f'Ignoring unreadable file "{version_path}"')