Skip to content

Commit

Permalink
move variables to class const
Browse files Browse the repository at this point in the history
Signed-off-by: georgi-l95 <glazarov95@gmail.com>
  • Loading branch information
georgi-l95 committed Oct 10, 2022
1 parent f11793d commit 0b9baab
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions packages/relay/src/lib/eth.ts
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,9 @@ export class EthImpl implements Eth {
static defaultGasUsedRatio = EthImpl.numberTo0x(0.5);
static feeHistoryZeroBlockCountResponse = { gasUsedRatio: null, oldestBlock: EthImpl.zeroHex };
static feeHistoryEmptyResponse = { baseFeePerGas: [], gasUsedRatio: [], reward: [], oldestBlock: EthImpl.zeroHex };
static redirectBytecodePrefix = '6080604052348015600f57600080fd5b506000610167905077618dc65e';
static redirectBytecodePostfix = '600052366000602037600080366018016008845af43d806000803e8160008114605857816000f35b816000fdfea2646970667358221220d8378feed472ba49a0005514ef7087017f707b45fb9bf56bb81bb93ff19a238b64736f6c634300080b0033';


// endpoint metric callerNames
static ethCall = 'eth_call';
Expand Down Expand Up @@ -1015,9 +1018,7 @@ export class EthImpl implements Eth {
}

private static redirectBytecodeAddressReplace(address: string): string {
const redirectBytecodePrefix = '6080604052348015600f57600080fd5b506000610167905077618dc65e';
const redirectBytecodePostfix = '600052366000602037600080366018016008845af43d806000803e8160008114605857816000f35b816000fdfea2646970667358221220d8378feed472ba49a0005514ef7087017f707b45fb9bf56bb81bb93ff19a238b64736f6c634300080b0033';
return `${redirectBytecodePrefix}${address.slice(2)}${redirectBytecodePostfix}`;
return `${this.redirectBytecodePrefix}${address.slice(2)}${this.redirectBytecodePostfix}`;
}

/**
Expand Down

0 comments on commit 0b9baab

Please sign in to comment.