fixed location of where tracks where saved (sys.path error), image should now be built upon correct, most recent data

This commit is contained in:
Xevion
2019-12-23 15:30:00 -06:00
parent 7f1a6a6e25
commit d788c3c915
2 changed files with 6 additions and 6 deletions

View File

@@ -24,7 +24,7 @@ def main():
sp = spotipy.Spotify(auth=token)
logging.info('Authorized with Spotify via Spotipy')
tracks_folder = os.path.join(sys.path[0], 'tracks')
tracks_folder = os.path.join(os.path.dirname(__file__), 'tracks')
logging.warning('Clearing all files in tracks folder for new files')
if os.path.exists(tracks_folder):
shutil.rmtree(tracks_folder) # Delete folder and all contents (old track files)