Skip to content

Commit

Permalink
Use custom hexlify for EIP 1559 gas estimation params (#4102)
Browse files Browse the repository at this point in the history
  • Loading branch information
FrederikBolding authored Aug 27, 2021
1 parent 2ae9511 commit b294aa9
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 2 deletions.
3 changes: 1 addition & 2 deletions src/services/ApiService/Gas/eip1559.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
import { hexlify } from '@ethersproject/bytes';
import BigNumber from 'bignumber.js';

import { ProviderHandler } from '@services/EthService';
import { bigify, fromWei, getDecimalFromEtherUnit, toWei } from '@utils';
import { bigify, fromWei, getDecimalFromEtherUnit, hexlify, toWei } from '@utils';

import { MAX_GAS_FAST } from './constants';

Expand Down
4 changes: 4 additions & 0 deletions src/utils/hexlify.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
import { addHexPrefix } from './addHexPrefix';
import { bigify, BigifySupported } from './bigify';

export const hexlify = (input: BigifySupported) => addHexPrefix(bigify(input).toString(16));
1 change: 1 addition & 0 deletions src/utils/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -109,3 +109,4 @@ export { mapAsync, filterAsync } from './asyncFilter';
export { goBack } from './navigation';
export { addHexPrefix } from './addHexPrefix';
export * from './typedTx';
export * from './hexlify';

0 comments on commit b294aa9

Please sign in to comment.