@@ -3,6 +3,7 @@ import path from 'path'
3
3
4
4
import { loadGraphHorizon , loadSubgraphService } from '@graphprotocol/toolshed/deployments'
5
5
import { logDebug , logError } from './logger'
6
+ import { getAccounts } from './accounts'
6
7
import { getAddressBookPath } from './config'
7
8
import { GraphPluginError } from './error'
8
9
import { HardhatEthersProvider } from '@nomicfoundation/hardhat-ethers/internal/hardhat-ethers-provider'
@@ -12,7 +13,6 @@ import { lazyFunction } from 'hardhat/plugins'
12
13
import type { HardhatConfig , HardhatRuntimeEnvironment , HardhatUserConfig } from 'hardhat/types'
13
14
import type { GraphDeployments } from '@graphprotocol/toolshed/deployments'
14
15
import type { GraphRuntimeEnvironmentOptions } from './types'
15
- import { getAccounts } from './accounts'
16
16
17
17
export const greExtendConfig = ( config : HardhatConfig , userConfig : Readonly < HardhatUserConfig > ) => {
18
18
const userPath = userConfig . paths ?. graph
@@ -50,7 +50,7 @@ export const greExtendEnvironment = (hre: HardhatRuntimeEnvironment) => {
50
50
51
51
// Build the Graph Runtime Environment (GRE) for each deployment
52
52
const provider = new HardhatEthersProvider ( hre . network . provider , hre . network . name )
53
- const greDeployments : GraphDeployments = { } as GraphDeployments
53
+ const greDeployments = { } as GraphDeployments
54
54
55
55
for ( const deployment of deployments ) {
56
56
logDebug ( `== Initializing deployment: ${ deployment } ==` )
@@ -82,7 +82,7 @@ export const greExtendEnvironment = (hre: HardhatRuntimeEnvironment) => {
82
82
}
83
83
84
84
// Accounts
85
- const accounts = getAccounts ( provider , chainId , greDeployments . horizon ? .contracts ? .GraphToken ? .target )
85
+ const accounts = getAccounts ( provider , chainId , greDeployments . horizon . contracts . GraphToken . target )
86
86
87
87
logDebug ( 'GRE initialized successfully!' )
88
88
0 commit comments