-
Notifications
You must be signed in to change notification settings - Fork 13
Send transaction cost to factory deployer only if its balance is empty #94
Copy link
Copy link
Open
Description
in FactoryDeployer.js script, the factory deployer account is funded with some tokens to allow the deployment of the factory.
Lines 26 to 31 in 8dc9ea3
| console.debug(`→ Factory is not yet deployed on this network`); | |
| await waitTx( | |
| wallet.sendTransaction({ to: FACTORY.deployer, value: FACTORY.cost }), | |
| ); | |
| await waitTx(wallet.provider.sendTransaction(FACTORY.tx)); | |
| console.debug(`→ Factory successfully deployed`); |
With the current version, if the factory deployment tx fails funds are sent with every retry, which results in loosing funds of the sender account.
We need to add a control to only send funds if the deployer account is empty (or less than FACTORY.cost).
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels