From c78fa2fb29b29b71da8d290c11a8a91f3829c1ab Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Germ=C3=A1n=20Mart=C3=ADnez?= Date: Mon, 29 Apr 2019 13:13:32 +0200 Subject: [PATCH] Update safeMaster setup parameters --- src/logic/contracts/safeContracts.js | 3 ++- src/logic/wallets/ethAddresses.js | 2 ++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/src/logic/contracts/safeContracts.js b/src/logic/contracts/safeContracts.js index c1116a91..b875f9e6 100644 --- a/src/logic/contracts/safeContracts.js +++ b/src/logic/contracts/safeContracts.js @@ -5,6 +5,7 @@ import { getWeb3 } from '~/logic/wallets/getWeb3' import GnosisSafeSol from '#/GnosisSafe.json' import ProxyFactorySol from '#/ProxyFactory.json' import { calculateGasOf, calculateGasPrice } from '~/logic/wallets/ethTransactions' +import { ZERO_ADDRESS } from '~/logic/wallets/ethAddresses' let proxyFactoryMaster let safeMaster @@ -61,7 +62,7 @@ export const getSafeMasterContract = async () => { export const deploySafeContract = async (safeAccounts: string[], numConfirmations: number, userAccount: string) => { const gnosisSafeData = await safeMaster.contract.methods - .setup(safeAccounts, numConfirmations, '0x0000000000000000000000000000000000000000', '0x') + .setup(safeAccounts, numConfirmations, ZERO_ADDRESS, '0x', ZERO_ADDRESS, 0, ZERO_ADDRESS) .encodeABI() const proxyFactoryData = proxyFactoryMaster.contract.methods .createProxy(safeMaster.address, gnosisSafeData) diff --git a/src/logic/wallets/ethAddresses.js b/src/logic/wallets/ethAddresses.js index df1ec918..b116e2b9 100644 --- a/src/logic/wallets/ethAddresses.js +++ b/src/logic/wallets/ethAddresses.js @@ -1,4 +1,6 @@ // @flow +export const ZERO_ADDRESS = ' 0x0000000000000000000000000000000000000000' + export const sameAddress = (firstAddress: string, secondAddress: string): boolean => { if (!firstAddress) { return false