mirror of
https://github.com/strapi/strapi.git
synced 2025-12-27 23:24:03 +00:00
add comment
This commit is contained in:
parent
bd823964aa
commit
113f2b093b
@ -153,6 +153,7 @@ const processEntriesWith = async (processFn, { trx, model, attributesToMigrate }
|
||||
|
||||
const migrateForBookshelf = async ({ ORM, model, attributesToMigrate }) => {
|
||||
if (['pg', 'mysql'].includes(model.client)) {
|
||||
// create table outside of the transaction because mysql doesn't accept the creation inside
|
||||
await createTmpTable({ ORM, attributesToMigrate, model });
|
||||
await ORM.knex.transaction(async trx => {
|
||||
await processEntriesWith(batchInsertInTmpTable, { ORM, trx, model, attributesToMigrate });
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user