mirror of
https://github.com/AUTOMATIC1111/stable-diffusion-webui.git
synced 2025-08-04 11:12:35 +00:00
Fix up string formatting/concatenation to f-strings where feasible
This commit is contained in:
@@ -74,7 +74,7 @@ class StyleDatabase:
|
||||
def save_styles(self, path: str) -> None:
|
||||
# Always keep a backup file around
|
||||
if os.path.exists(path):
|
||||
shutil.copy(path, path + ".bak")
|
||||
shutil.copy(path, f"{path}.bak")
|
||||
|
||||
fd = os.open(path, os.O_RDWR|os.O_CREAT)
|
||||
with os.fdopen(fd, "w", encoding="utf-8-sig", newline='') as file:
|
||||
|
Reference in New Issue
Block a user