From c9437d7c6769b1a5484db73ad1eec3a72bd84146 Mon Sep 17 00:00:00 2001 From: louis <869322496@qq.com> Date: Wed, 27 Mar 2024 14:18:11 +0800 Subject: [PATCH] fix: minio --- src/modules/netdisk/manager/manage.service.ts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/modules/netdisk/manager/manage.service.ts b/src/modules/netdisk/manager/manage.service.ts index d1a1209..9706867 100644 --- a/src/modules/netdisk/manager/manage.service.ts +++ b/src/modules/netdisk/manager/manage.service.ts @@ -4,7 +4,6 @@ import { isEmpty } from 'lodash'; import { ConfigKeyPaths } from '~/config'; import { generateRandomValue } from '~/utils'; import { SFileInfo, SFileInfoDetail, SFileList } from './manage.class'; -import * as Minio from 'Minio'; import { InjectMinio } from 'nestjs-minio'; import { Client } from 'minio'; @@ -29,7 +28,7 @@ export class NetDiskManageService { return new Promise((resolve, reject) => { try { const fileStream = this.minioClient.listObjects(this.ossConfig.bucket, prefix, false); - this.readStreamData(fileStream).then(respBody => { + this.readStreamData(fileStream).then(respBody => { console.log(respBody); const dirs = respBody.filter(item => 'prefix' in item).map(item => item.prefix); const files = respBody.filter(item => !('prefix' in item));