tecuts commited on
Commit
6a8c623
·
verified ·
1 Parent(s): 036b1fb

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -193,9 +193,9 @@ def download_track(request: DownloadRequest):
193
  logger.info(f"Downloaded file size: {file_size} bytes")
194
 
195
  # Return the download URL
196
- relative_path = os.path.relpath(filepath, "downloads")
197
  # Remove spaces from the relative path
198
- download_url = f"{BASE_URL}/downloads/{quote(str({relative_path}))}"
199
  logger.info(f"Download successful: {download_url}")
200
  return {"download_url": download_url}
201
  except Exception as e:
 
193
  logger.info(f"Downloaded file size: {file_size} bytes")
194
 
195
  # Return the download URL
196
+ relative_path = quote(str(os.path.relpath(filepath, "downloads")))
197
  # Remove spaces from the relative path
198
+ download_url = f"{BASE_URL}/downloads/{relative_path}"
199
  logger.info(f"Download successful: {download_url}")
200
  return {"download_url": download_url}
201
  except Exception as e: