mirror of
https://github.com/hcengineering/platform.git
synced 2025-04-13 03:40:48 +00:00
QFIX: Child info could be empty (#3785)
Signed-off-by: Andrey Sobolev <haiodo@gmail.com>
This commit is contained in:
parent
9a4fa752de
commit
c6065d094a
@ -103,7 +103,7 @@ async function fixSpentTime (client: MigrationClient): Promise<void> {
|
||||
const issues = await client.find<Issue>(DOMAIN_TASK, { reportedTime: { $gt: 0 } })
|
||||
for (const issue of issues) {
|
||||
const childInfo = issue.childInfo
|
||||
for (const child of childInfo) {
|
||||
for (const child of childInfo ?? []) {
|
||||
child.reportedTime = child.reportedTime * 8
|
||||
}
|
||||
await client.update(DOMAIN_TASK, { _id: issue._id }, { reportedTime: issue.reportedTime * 8, childInfo })
|
||||
|
Loading…
Reference in New Issue
Block a user