minor cleanup
This commit is contained in:
parent
4a4cfc5d48
commit
6b9acb8c6b
@ -34,5 +34,5 @@ app.post('/relay', controller.tornadoWithdraw)
|
||||
// app.post('/v1/miningWithdraw', controller.miningWithdraw)
|
||||
|
||||
worker.start()
|
||||
app.listen(port || 8000)
|
||||
console.log(`Relayer ${version} started on port ${port || 8000}`)
|
||||
app.listen(port)
|
||||
console.log(`Relayer ${version} started on port ${port}`)
|
||||
|
@ -30,12 +30,9 @@ async function fetchTree() {
|
||||
}
|
||||
|
||||
async function start() {
|
||||
web3 = new Web3(rpcUrl, null, { transactionConfirmationBlocks: 1 })
|
||||
const account = web3.eth.accounts.privateKeyToAccount('0x' + privateKey)
|
||||
web3.eth.accounts.wallet.add('0x' + privateKey)
|
||||
web3.eth.defaultAccount = account.address
|
||||
updateConfig({ rewardAccount: account.address })
|
||||
web3 = new Web3(rpcUrl)
|
||||
txManager = new TxManager({ privateKey, rpcUrl })
|
||||
updateConfig({ rewardAccount: txManager.address })
|
||||
queue.process(process)
|
||||
redisSubscribe.subscribe('treeUpdate', fetchTree)
|
||||
await fetchTree()
|
||||
|
Loading…
Reference in New Issue
Block a user