File tree Expand file tree Collapse file tree 1 file changed +4
-18
lines changed
packages/job-worker/src/ingest Expand file tree Collapse file tree 1 file changed +4
-18
lines changed Original file line number Diff line number Diff line change @@ -420,31 +420,17 @@ async function updatePartInstancesSegmentIds(
420
420
for ( const renameRule of renameRules . values ( ) ) {
421
421
oldSegmentIds . push ( ...renameRule . fromSegmentIds )
422
422
}
423
- const [ badPartInstances , badParts ] = await Promise . all ( [
424
- await context . directCollections . PartInstances . findFetch ( {
425
- rundownId : ingestModel . rundownId ,
426
- segmentId : { $in : oldSegmentIds } ,
427
- } ) ,
428
- await context . directCollections . Parts . findFetch ( {
429
- rundownId : ingestModel . rundownId ,
430
- segmentId : { $in : oldSegmentIds } ,
431
- } ) ,
432
- ] )
423
+ const badPartInstances = await context . directCollections . PartInstances . findFetch ( {
424
+ rundownId : ingestModel . rundownId ,
425
+ segmentId : { $in : oldSegmentIds } ,
426
+ } )
433
427
if ( badPartInstances . length > 0 ) {
434
428
logger . error (
435
429
`updatePartInstancesSegmentIds: Failed to update all PartInstances using old SegmentIds "${ JSON . stringify (
436
430
oldSegmentIds
437
431
) } ": ${ JSON . stringify ( badPartInstances ) } , writeOps: ${ JSON . stringify ( writeOps ) } `
438
432
)
439
433
}
440
-
441
- if ( badParts . length > 0 ) {
442
- logger . error (
443
- `updatePartInstancesSegmentIds: Failed to update all Parts using old SegmentIds "${ JSON . stringify (
444
- oldSegmentIds
445
- ) } ": ${ JSON . stringify ( badParts ) } , writeOps: ${ JSON . stringify ( writeOps ) } `
446
- )
447
- }
448
434
// End of the temporary section
449
435
}
450
436
}
You can’t perform that action at this time.
0 commit comments