From 99d4858cdcc5b0d1f8dc0e96bd21e18f5978e2d9 Mon Sep 17 00:00:00 2001 From: yupix Date: Fri, 29 Sep 2023 02:52:31 +0000 Subject: [PATCH] =?UTF-8?q?chore:=20drivefile=E3=81=AEcompleted=E3=82=92?= =?UTF-8?q?=E4=B8=80=E5=AE=9A=E4=BB=A5=E4=B8=8A=E3=81=A7=E6=B6=88=E3=81=99?= =?UTF-8?q?=E3=82=88=E3=81=86=E3=81=AB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/migration/drive.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/migration/drive.ts b/src/migration/drive.ts index 848255c80..f8e8e65cd 100644 --- a/src/migration/drive.ts +++ b/src/migration/drive.ts @@ -68,6 +68,11 @@ export async function migrateDriveFile( isSensitive: file.isSensitive, isLink: file.isLink, }); + + if (await driveFileQueue.getCompletedCount() > 1000) { + await driveFileQueue.clean(0, "completed"); + } + logger.succ(`DriveFile: ${driveFileId} の移行が完了しました`); return createdDriveFile; }