Skip to content

Commit

Permalink
pkgres: fix tiny leak in template loader
Browse files Browse the repository at this point in the history
  • Loading branch information
9001 committed Sep 20, 2024
1 parent 58cf01c commit 66b260c
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion copyparty/httpsrv.py
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,8 @@


def load_jinja2_resource(E: EnvParams, name: str):
return load_resource(E, "web/" + name, "r").read()
with load_resource(E, "web/" + name, "r") as f:
return f.read()


class HttpSrv(object):
Expand Down

0 comments on commit 66b260c

Please sign in to comment.