Skip to content

Commit d971f6d

Browse files
authored
feat: not init minio client in file init (#1243)
2 parents 593a1b6 + 5b8490c commit d971f6d

1 file changed

Lines changed: 1 addition & 2 deletions

File tree

src/backend/bisheng/api/v1/endpoints.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,6 @@ def process_graph_cached_task(*args, **kwargs):
3737
# build router
3838
router = APIRouter(tags=['Base'])
3939

40-
minio_client = MinioClient()
41-
4240

4341
@router.get('/all')
4442
def get_all():
@@ -345,6 +343,7 @@ async def create_upload_file(file: UploadFile, flow_id: str):
345343
@router.get('/download')
346344
async def get_download_url(object_name: str):
347345
# Cache file
346+
minio_client = MinioClient()
348347
try:
349348
url = minio_client.get_share_link(object_name)
350349
return resp_200(url)

0 commit comments

Comments
 (0)