chore: update proxy contract for goerli

This commit is contained in:
nikdementev 2021-03-24 12:22:55 +03:00 committed by Nikita Dement'ev
parent 6cc62e7d94
commit 80f9d4017f
3 changed files with 11 additions and 2 deletions

@ -1,6 +1,6 @@
{ {
"name": "relay", "name": "relay",
"version": "4.0.8", "version": "4.0.9",
"description": "Relayer for Tornado.cash privacy solution. https://tornado.cash", "description": "Relayer for Tornado.cash privacy solution. https://tornado.cash",
"scripts": { "scripts": {
"server": "node src/server.js", "server": "node src/server.js",

@ -23,5 +23,6 @@ module.exports = {
[jobType.MINING_REWARD]: 455000, [jobType.MINING_REWARD]: 455000,
[jobType.MINING_WITHDRAW]: 400000, [jobType.MINING_WITHDRAW]: 400000,
}, },
tornadoProxy: '0x454d870a72e29d5E5697f635128D18077BD04C60',
minimumBalance: '1000000000000000000', minimumBalance: '1000000000000000000',
} }

@ -22,6 +22,7 @@ const {
gasLimits, gasLimits,
instances, instances,
oracleRpcUrl, oracleRpcUrl,
tornadoProxy,
tornadoServiceFee, tornadoServiceFee,
miningServiceFee, miningServiceFee,
} = require('./config') } = require('./config')
@ -84,7 +85,14 @@ async function start() {
}) })
swap = new web3.eth.Contract(swapABI, await resolver.resolve(torn.rewardSwap.address)) swap = new web3.eth.Contract(swapABI, await resolver.resolve(torn.rewardSwap.address))
minerContract = new web3.eth.Contract(miningABI, await resolver.resolve(torn.miningV2.address)) minerContract = new web3.eth.Contract(miningABI, await resolver.resolve(torn.miningV2.address))
proxyContract = new web3.eth.Contract(tornadoProxyABI, await resolver.resolve(torn.tornadoProxy.address)) if (netId === 5) {
proxyContract = new web3.eth.Contract(tornadoProxyABI, tornadoProxy)
} else {
proxyContract = new web3.eth.Contract(
tornadoProxyABI,
await resolver.resolve(torn.tornadoProxy.address),
)
}
redisSubscribe.subscribe('treeUpdate', fetchTree) redisSubscribe.subscribe('treeUpdate', fetchTree)
await fetchTree() await fetchTree()
const provingKeys = { const provingKeys = {