Skip to content

Commit

Permalink
fix: small fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
Amuhar committed Aug 9, 2023
1 parent 98dd177 commit 03cf05d
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 12 deletions.
2 changes: 0 additions & 2 deletions src/common/registry/fetch/key-batch.fetch.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,6 @@ export class RegistryKeyBatchFetchService {

private getContract(moduleAddress: string) {
return this.contract.attach(moduleAddress);

// return Registry__factory.connect(moduleAddress, this.provider);
}

/**
Expand Down
5 changes: 1 addition & 4 deletions src/common/registry/fetch/key.fetch.ts
Original file line number Diff line number Diff line change
@@ -1,13 +1,11 @@
/* eslint-disable @typescript-eslint/no-explicit-any */
import { Inject, Injectable } from '@nestjs/common';
import { rangePromise } from '@lido-nestjs/utils';
// import { Registry__factory } from '@lido-nestjs/contracts';
import { CallOverrides } from './interfaces/overrides.interface';
import { RegistryKey } from './interfaces/key.interface';
import { RegistryOperatorFetchService } from './operator.fetch';
import { REGISTRY_KEY_BATCH_SIZE } from './key.constants';
import { ExecutionProvider } from 'common/execution-provider';
import { REGISTRY_CONTRACT_TOKEN, Registry__factory, Registry } from '@lido-nestjs/contracts';
import { REGISTRY_CONTRACT_TOKEN, Registry } from '@lido-nestjs/contracts';

@Injectable()
export class RegistryKeyFetchService {
Expand All @@ -18,7 +16,6 @@ export class RegistryKeyFetchService {

private getContract(moduleAddress: string) {
return this.contract.attach(moduleAddress);
// return Registry__factory.connect(moduleAddress, this.provider);
}

/** fetches one key */
Expand Down
4 changes: 1 addition & 3 deletions src/common/registry/fetch/meta.fetch.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,14 @@
import { Inject, Injectable } from '@nestjs/common';
// import { Registry__factory } from '@lido-nestjs/contracts';
import { CallOverrides } from './interfaces/overrides.interface';
import { ExecutionProvider } from 'common/execution-provider';
import { REGISTRY_CONTRACT_TOKEN, Registry__factory, Registry } from '@lido-nestjs/contracts';
import { REGISTRY_CONTRACT_TOKEN, Registry } from '@lido-nestjs/contracts';

@Injectable()
export class RegistryMetaFetchService {
constructor(@Inject(REGISTRY_CONTRACT_TOKEN) private contract: Registry) {}

private getContract(moduleAddress: string) {
return this.contract.attach(moduleAddress);
// return Registry__factory.connect(moduleAddress, this.provider);
}

/** fetches keys operation index */
Expand Down
4 changes: 1 addition & 3 deletions src/common/registry/fetch/operator.fetch.ts
Original file line number Diff line number Diff line change
@@ -1,19 +1,17 @@
/* eslint-disable @typescript-eslint/no-explicit-any */
import { Inject, Injectable } from '@nestjs/common';
import { rangePromise } from '@lido-nestjs/utils';
import { REGISTRY_CONTRACT_TOKEN, Registry__factory, Registry } from '@lido-nestjs/contracts';
import { REGISTRY_CONTRACT_TOKEN, Registry } from '@lido-nestjs/contracts';
import { CallOverrides } from './interfaces/overrides.interface';
import { RegistryOperator } from './interfaces/operator.interface';
import { REGISTRY_OPERATORS_BATCH_SIZE } from './operator.constants';
import { ExecutionProvider } from 'common/execution-provider';

@Injectable()
export class RegistryOperatorFetchService {
constructor(@Inject(REGISTRY_CONTRACT_TOKEN) private contract: Registry) {}

private getContract(moduleAddress: string) {
return this.contract.attach(moduleAddress);
// return Registry__factory.connect(moduleAddress, this.provider);
}

/** fetches number of operators */
Expand Down

0 comments on commit 03cf05d

Please sign in to comment.