Browse Source

refactor(core): Remove unused code in applyCollectionFiltersInternal

Thierry Tournie 3 years ago
parent
commit
abfafeb452
1 changed files with 0 additions and 4 deletions
  1. 0 4
      packages/core/src/service/services/collection.service.ts

+ 0 - 4
packages/core/src/service/services/collection.service.ts

@@ -601,10 +601,8 @@ export class CollectionService implements OnModuleInit {
         try {
             // First we remove variants that are no longer in the collection
             const chunkedDeleteIds = this.chunkArray(toDeleteIds, 500)
-            let chunkDeleteVariant = 0
 
             for (const chunkedDeleteId of chunkedDeleteIds) {
-                chunkDeleteVariant++
                 await this.connection.rawConnection
                   .createQueryBuilder()
                   .relation(Collection, 'productVariants')
@@ -614,10 +612,8 @@ export class CollectionService implements OnModuleInit {
 
             // Then we add variants have been added
             const chunkedAddIds = this.chunkArray(toAddIds, 500)
-            let chunkVariant = 0
 
             for (const chunkedAddId of chunkedAddIds) {
-            chunkVariant++
             await this.connection.rawConnection
                 .createQueryBuilder()
                 .relation(Collection, 'productVariants')