Skip to content

Commit

Permalink
fix: remove unused stop
Browse files Browse the repository at this point in the history
  • Loading branch information
pcarranzav committed Jul 28, 2023
1 parent c0d5892 commit 70e0057
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 10 deletions.
9 changes: 0 additions & 9 deletions packages/indexer-common/src/allocations/query-fees.ts
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,6 @@ export class AllocationReceiptCollector implements ReceiptCollector {
private voucherRedemptionBatchThreshold: BigNumber
private voucherRedemptionMaxBatchSize: number
private protocolNetwork: string
private stop: boolean

constructor({
logger,
Expand All @@ -99,7 +98,6 @@ export class AllocationReceiptCollector implements ReceiptCollector {
allocationExchange,
networkSpecification,
}: AllocationReceiptCollectorOptions) {
this.stop = false
this.logger = logger.child({ component: 'AllocationReceiptCollector' })
this.metrics = registerReceiptMetrics(metrics, networkSpecification.networkIdentifier)
this.transactionManager = transactionManager
Expand Down Expand Up @@ -233,10 +231,6 @@ export class AllocationReceiptCollector implements ReceiptCollector {
}
}

async stopCollectingReceipts(): Promise<void> {
this.stop = true
}

private startReceiptCollecting() {
this.receiptsToCollect = new DHeap<AllocationReceiptsBatch>(null, {
compare: (t1, t2) => t1.timeout - t2.timeout,
Expand Down Expand Up @@ -268,9 +262,6 @@ export class AllocationReceiptCollector implements ReceiptCollector {

private startVoucherProcessing() {
timer(30_000).pipe(async () => {
if (this.stop) {
return
}
const pendingVouchers = await this.pendingVouchers() // Ordered by value

const logger = this.logger.child({})
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,6 @@ const teardownEach = async () => {
}

const teardownAll = async () => {
//await network.receiptCollector.stopCollectingReceipts()
//await sequelize.drop({})
}

Expand Down

0 comments on commit 70e0057

Please sign in to comment.