add Infura wallet support
This commit is contained in:
parent
05e7889dc0
commit
ac89f0e5e9
9 changed files with 472 additions and 513 deletions
11
lib/plugins/wallet/infura/infura.js
Normal file
11
lib/plugins/wallet/infura/infura.js
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
const _ = require('lodash/fp')
|
||||
const base = require('../geth/base')
|
||||
|
||||
function run (account) {
|
||||
const apiKey = account.apiKey
|
||||
if (!apiKey) throw new Error('Need to configure API key for Infura')
|
||||
|
||||
base.connect(`https://mainnet.infura.io/${apiKey}`)
|
||||
}
|
||||
|
||||
module.exports = _.merge(base, {run})
|
||||
Loading…
Add table
Add a link
Reference in a new issue