diff options
author | Aarni Koskela <akx@iki.fi> | 2023-05-09 19:17:58 +0000 |
---|---|---|
committer | Aarni Koskela <akx@iki.fi> | 2023-05-09 19:25:39 +0000 |
commit | 3ba6c3c83c0983a025c7bddc08bb7f49481b3cbb (patch) | |
tree | 77b2bea31c0e94ac67fddf86fdc7cba65a24af2c /modules/hashes.py | |
parent | 8fb16ceb288a93f6ecaa45a0afcb3db718333e3e (diff) | |
download | stable-diffusion-webui-gfx803-3ba6c3c83c0983a025c7bddc08bb7f49481b3cbb.tar.gz stable-diffusion-webui-gfx803-3ba6c3c83c0983a025c7bddc08bb7f49481b3cbb.tar.bz2 stable-diffusion-webui-gfx803-3ba6c3c83c0983a025c7bddc08bb7f49481b3cbb.zip |
Fix up string formatting/concatenation to f-strings where feasible
Diffstat (limited to 'modules/hashes.py')
-rw-r--r-- | modules/hashes.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/modules/hashes.py b/modules/hashes.py index 83272a07..032120f4 100644 --- a/modules/hashes.py +++ b/modules/hashes.py @@ -13,7 +13,7 @@ cache_data = None def dump_cache():
- with filelock.FileLock(cache_filename+".lock"):
+ with filelock.FileLock(f"{cache_filename}.lock"):
with open(cache_filename, "w", encoding="utf8") as file:
json.dump(cache_data, file, indent=4)
@@ -22,7 +22,7 @@ def cache(subsection): global cache_data
if cache_data is None:
- with filelock.FileLock(cache_filename+".lock"):
+ with filelock.FileLock(f"{cache_filename}.lock"):
if not os.path.isfile(cache_filename):
cache_data = {}
else:
|