Skip to content

Commit 5dc5532

Browse files
committed
Formatting
1 parent f26ee78 commit 5dc5532

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

platform_utils/paths.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,8 @@ def app_data_path(app_name: str) -> str:
5353
# Use roaming=True to match winpaths.get_appdata() behavior (AppData\Roaming)
5454
path = platformdirs.user_data_dir(roaming=True)
5555
elif is_mac:
56-
path = os.path.join(os.path.expanduser("~"), "Library", "Application Support")
56+
path = os.path.join(os.path.expanduser(
57+
"~"), "Library", "Application Support")
5758
elif is_linux:
5859
path = os.path.expanduser("~")
5960
app_name = ".%s" % app_name.replace(" ", "_")
@@ -175,7 +176,8 @@ def safe_filename(filename: Union[str, bytes]) -> str:
175176
"""
176177
SAFE_FILE_CHARS = "'-_.()[]{}!@#$%^&+=`~ "
177178
filename = unicode(filename)
178-
new_filename = "".join(c for c in filename if c in SAFE_FILE_CHARS or c.isalnum())
179+
new_filename = "".join(
180+
c for c in filename if c in SAFE_FILE_CHARS or c.isalnum())
179181
# Windows doesn't like directory names ending in space, macs consider filenames beginning with a dot as hidden, and windows removes dots at the ends of filenames.
180182
return new_filename.strip(" .")
181183

0 commit comments

Comments
 (0)