Skip to content

Commit

Permalink
fix: the correct data directory is now used when TGPY_DATA is set to …
Browse files Browse the repository at this point in the history
…a relative path and restart is called
  • Loading branch information
vanutp committed May 6, 2024
1 parent 36f9a64 commit f483d6c
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions tgpy/api/directories.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@

if env_tgpy_data := os.getenv('TGPY_DATA'):
DATA_DIR = Path(env_tgpy_data).absolute()
os.environ['TGPY_DATA'] = str(DATA_DIR)
else:
# noinspection PyTypeChecker
DATA_DIR = Path(appdirs.user_config_dir('tgpy', appauthor=False))
Expand Down

0 comments on commit f483d6c

Please sign in to comment.