This commit is contained in:
SunSeekerX
2025-12-31 02:28:51 +08:00
parent fba18000e5
commit 666b0120b7
2 changed files with 105 additions and 35 deletions

View File

@@ -41,7 +41,9 @@ async function migrate() {
stats.dailyIndex++
}
}
if (keys.length > 0) await pipeline.exec()
if (keys.length > 0) {
await pipeline.exec()
}
} while (cursor !== '0')
console.log(` 已处理 ${stats.dailyIndex}`)
@@ -63,7 +65,9 @@ async function migrate() {
stats.hourlyIndex++
}
}
if (keys.length > 0) await pipeline.exec()
if (keys.length > 0) {
await pipeline.exec()
}
} while (cursor !== '0')
console.log(` 已处理 ${stats.hourlyIndex}`)
@@ -85,7 +89,9 @@ async function migrate() {
stats.modelDailyIndex++
}
}
if (keys.length > 0) await pipeline.exec()
if (keys.length > 0) {
await pipeline.exec()
}
} while (cursor !== '0')
console.log(` 已处理 ${stats.modelDailyIndex}`)
@@ -113,7 +119,9 @@ async function migrate() {
stats.modelHourlyIndex++
}
}
if (keys.length > 0) await pipeline.exec()
if (keys.length > 0) {
await pipeline.exec()
}
} while (cursor !== '0')
console.log(` 已处理 ${stats.modelHourlyIndex}`)