Commit f5115e27 authored by Kelvin Fichter's avatar Kelvin Fichter

fix: genesis output format

parent 6c69d92e
......@@ -158,7 +158,8 @@ export const loadSurgeryData = async (
return {
configs,
dump,
genesis: genesisDump,
genesis,
genesisDump,
pools,
poolHashCache,
etherscanDump,
......
......@@ -50,7 +50,7 @@ export const handlers: {
return account
},
[AccountType.PREDEPLOY_WIPE]: (account, data) => {
const genesisAccount = findAccount(data.genesis, account.address)
const genesisAccount = findAccount(data.genesisDump, account.address)
return {
...account,
code: genesisAccount.code,
......@@ -58,7 +58,7 @@ export const handlers: {
}
},
[AccountType.PREDEPLOY_NO_WIPE]: (account, data) => {
const genesisAccount = findAccount(data.genesis, account.address)
const genesisAccount = findAccount(data.genesisDump, account.address)
return {
...account,
code: genesisAccount.code,
......
......@@ -17,7 +17,7 @@ const doGenesisSurgery = async (
const input = data.dump.slice(data.configs.startIndex, data.configs.endIndex)
// Insert any accounts in the genesis that aren't already in the state dump.
for (const account of data.genesis) {
for (const account of data.genesisDump) {
if (findAccount(input, account.address) === undefined) {
input.push(account)
}
......
......@@ -91,7 +91,8 @@ export type SupportedNetworks = 'mainnet' | 'kovan'
export interface SurgeryDataSources {
configs: SurgeryConfigs
dump: StateDump
genesis: StateDump
genesis: GenesisFile
genesisDump: StateDump
pools: UniswapPoolData[]
poolHashCache: PoolHashCache
etherscanDump: EtherscanContract[]
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment