File tree Expand file tree Collapse file tree 1 file changed +2
-1
lines changed Expand file tree Collapse file tree 1 file changed +2
-1
lines changed Original file line number Diff line number Diff line change 1
1
import { BadRequestException , Injectable , NotFoundException } from '@nestjs/common' ;
2
2
import { FACE_THUMBNAIL_SIZE , JOBS_ASSET_PAGINATION_SIZE } from 'src/constants' ;
3
3
import { StorageCore } from 'src/cores/storage.core' ;
4
- import { OnJob } from 'src/decorators' ;
4
+ import { Chunked , OnJob } from 'src/decorators' ;
5
5
import { BulkIdErrorReason , BulkIdResponseDto } from 'src/dtos/asset-ids.response.dto' ;
6
6
import { AuthDto } from 'src/dtos/auth.dto' ;
7
7
import {
@@ -241,6 +241,7 @@ export class PersonService extends BaseService {
241
241
return results ;
242
242
}
243
243
244
+ @Chunked ( )
244
245
private async delete ( people : PersonEntity [ ] ) {
245
246
await Promise . all ( people . map ( ( person ) => this . storageRepository . unlink ( person . thumbnailPath ) ) ) ;
246
247
await this . personRepository . delete ( people ) ;
You can’t perform that action at this time.
0 commit comments