cic-go/net/cic_net.go
Mohammed Sohail 3601b61c20
refactor: rpc provider
- provider now lives on its own
- existing modules need the provider as a param
2022-05-18 12:50:45 +03:00

19 lines
372 B
Go

package net
import (
"github.com/ethereum/go-ethereum/common"
"github.com/grassrootseconomics/cic-go/provider"
)
type CicNet struct {
provider *provider.Provider
tokenIndex common.Address
}
func NewCicNet(rpcProvider provider.Provider, tokenIndex common.Address) (*CicNet, error) {
return &CicNet{
provider: &rpcProvider,
tokenIndex: tokenIndex,
}, nil
}