|
@@ -49,7 +49,7 @@ def get_dependencies(name: str, file: str):
|
|
|
if name in libraries and libraries[name]['path'].exists():
|
|
|
filepath = Path(libraries[name]['path']).parent / file
|
|
|
if filepath.exists() and not filepath.is_dir():
|
|
|
- return FileResponse(file, media_type='text/javascript')
|
|
|
+ return FileResponse(filepath, media_type='text/javascript')
|
|
|
return FileResponse(libraries[name]['path'], media_type='text/javascript')
|
|
|
raise HTTPException(status_code=404, detail=f'dependency "{name}" not found')
|
|
|
|