mirror of
https://github.com/hcengineering/platform.git
synced 2025-05-25 01:15:14 +00:00
qfix reaction migration (#7985)
Signed-off-by: Alexey Zinoviev <alexey.zinoviev@xored.com>
This commit is contained in:
parent
f7792fb9ae
commit
7c3eb9050d
@ -201,7 +201,7 @@ async function migrateAccountsToSocialIds (client: MigrationClient): Promise<voi
|
|||||||
const socialIdByAccount = await getSocialIdByOldAccount(client)
|
const socialIdByAccount = await getSocialIdByOldAccount(client)
|
||||||
|
|
||||||
ctx.info('processing activity reactions ', {})
|
ctx.info('processing activity reactions ', {})
|
||||||
const iterator = await client.traverse(DOMAIN_ACTIVITY, { _class: activity.class.Reaction })
|
const iterator = await client.traverse(DOMAIN_REACTION, { _class: activity.class.Reaction })
|
||||||
|
|
||||||
try {
|
try {
|
||||||
let processed = 0
|
let processed = 0
|
||||||
@ -228,7 +228,7 @@ async function migrateAccountsToSocialIds (client: MigrationClient): Promise<voi
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (operations.length > 0) {
|
if (operations.length > 0) {
|
||||||
await client.bulk(DOMAIN_ACTIVITY, operations)
|
await client.bulk(DOMAIN_REACTION, operations)
|
||||||
}
|
}
|
||||||
|
|
||||||
processed += docs.length
|
processed += docs.length
|
||||||
@ -372,7 +372,7 @@ export const activityOperation: MigrateOperation = {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
state: 'accounts-to-social-ids',
|
state: 'accounts-to-social-ids-v2',
|
||||||
func: migrateAccountsToSocialIds
|
func: migrateAccountsToSocialIds
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user