Skip to content

Commit dda081e

Browse files
committed
fix xgd scan
1 parent 7ed54b7 commit dda081e

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

t_modules/t_main.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -297,14 +297,18 @@
297297
print(f"Found XDG-Downloads: {download_directory}")
298298

299299

300-
if os.getenv('XDG_MUSIC_DIR') and os.path.isdir(os.getenv('XDG_MUSIC_DIR')):
300+
if os.getenv('XDG_MUSIC_DIR'):
301301
music_directory = os.getenv('XDG_MUSIC_DIR')
302302
print("Override music to: " + music_directory)
303303

304-
if os.getenv('XDG_DOWNLOAD_DIR') and os.path.isdir(os.getenv('XDG_DOWNLOAD_DIR')):
304+
if os.getenv('XDG_DOWNLOAD_DIR'):
305305
download_directory = os.getenv('XDG_DOWNLOAD_DIR')
306306
print("Override downloads to: " + download_directory)
307307

308+
if music_directory:
309+
music_directory = os.path.expandvars(music_directory)
310+
if download_directory:
311+
download_directory = os.path.expandvars(download_directory)
308312

309313
if not os.path.isdir(music_directory):
310314
music_directory = None

0 commit comments

Comments
 (0)