Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
correction
  • Loading branch information
pythonpete32 authored Sep 5, 2022
1 parent 9e7d8c9 commit 878afd6
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/factory/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,15 @@ You can check the factory file to see more details, it consists of 5 methods, de

This method is used to deploy contracts listed in `./constants.ts`.

- Interface: `deployAndSetUpModule(moduleName, args, provider, chainId)`
- Interface: `deployAndSetUpModule(moduleName, args, provider, chainId, salt)`
- Arguments:
- `moduleName`: Name of the module to be deployed, note that it needs to exist as a key in the [CONTRACT_ADDRESSES](./constants.ts#L3-L12) object
- `args`: An object with two attributes: `value` and `types`
- In `value` it expects an array of the arguments of the `setUp` function of the module to deploy
- In `types` it expects an array of the types of every value
- `provider`: Ethereum provider, expects an instance of `JsonRpcProvider` from `ethers`
- `chainId`: Number of network to interact with
- `salt`: For the Create2 op code
- Returns: An object with the transaction built in order to be executed by the Safe, and the expected address of the new module, this will allow developers to batch the transaction of deployment + enable module on safe. Example:

```json
Expand Down Expand Up @@ -106,4 +107,4 @@ This method returns an object with the an instance of the factory contract and t
We use a deterministic deployment to deploy the factory and mastercopies of each module, so that they can be deployed with the same address on supported networks. You can check which networks are supported in the
[constants file](./constants.ts#L14-L22)

The [Singleton Factory](https://eips.ethereum.org/EIPS/eip-2470) is used to deploy the Module Factory. If it is not already deployed at the correct address on your network, the [`singleton-deployment` script file](./singleton-deployment.ts) will attempt to deploy it before deploying the Module Proxy Factory. If the Singleton Factory cannot be deployed to the correct address, the script will fail.
The [Singleton Factory](https://eips.ethereum.org/EIPS/eip-2470) is used to deploy the Module Factory. If it is not already deployed at the correct address on your network, the [`singleton-deployment` script file](./singleton-deployment.ts) will attempt to deploy it before deploying the Module Proxy Factory. If the Singleton Factory cannot be deployed to the correct address, the script will fail.

0 comments on commit 878afd6

Please sign in to comment.