Skip to content

Commit 820ab24

Browse files
Move the amount of eth to pay to the config files
1 parent f75cd1d commit 820ab24

File tree

5 files changed

+16
-9
lines changed

5 files changed

+16
-9
lines changed

contracts/script/deploy/AggregationModePaymentServiceDeployer.s.sol

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,13 @@ contract AggregationModePaymentServiceDeployer is Script {
1212

1313
address owner = stdJson.readAddress(configData, ".permissions.paymentServiceOwner");
1414
address recipient = stdJson.readAddress(configData, ".permissions.recipient");
15+
uint256 amountToPay = stdJson.readUint(configData, ".amounts.amountToPayInWei");
1516

1617
vm.startBroadcast();
1718

1819
AggregationModePaymentService implementation = new AggregationModePaymentService();
1920
ERC1967Proxy proxy =
20-
new ERC1967Proxy(address(implementation), abi.encodeWithSignature("initialize(address,address)", owner, recipient));
21+
new ERC1967Proxy(address(implementation), abi.encodeWithSignature("initialize(address,address,uint256)", owner, recipient, amountToPay));
2122

2223
vm.stopBroadcast();
2324

contracts/script/deploy/config/devnet/proof-aggregator-service.devnet.config.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,9 @@
99
"sp1AggregationProgramVKHash": "0x00d6e32a34f68ea643362b96615591c94ee0bf99ee871740ab2337966a4f77af",
1010
"risc0AggregationProgramImageId": "0x8908f01022827e80a5de71908c16ee44f4a467236df20f62e7c994491629d74c"
1111
},
12+
"amounts": {
13+
"amountToPayInWei": 1000000000000000000
14+
},
1215
"permissions": {
1316
"owner": "0x14dC79964da2C08b23698B3D3cc7Ca32193d9955",
1417
"paymentServiceOwner": "0x14dC79964da2C08b23698B3D3cc7Ca32193d9955",

contracts/scripts/anvil/state/alignedlayer-deployed-anvil-state.json

Lines changed: 1 addition & 1 deletion
Large diffs are not rendered by default.

contracts/src/core/AggregationModePaymentService.sol

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,13 +62,13 @@ contract AggregationModePaymentService is Initializable, OwnableUpgradeable, UUP
6262
* @notice Initializes the contract and transfers ownership to the provided address.
6363
* @param _owner Address that becomes the contract owner.
6464
*/
65-
function initialize(address _owner, address _paymentFundsRecipient) public initializer {
65+
function initialize(address _owner, address _paymentFundsRecipient, uint256 _amountToPayInWei) public initializer {
6666
__Ownable_init();
6767
__UUPSUpgradeable_init();
6868
_transferOwnership(_owner);
6969

7070
paymentExpirationTimeSeconds = PAYMENT_VALID_UNTIL_SECONDS;
71-
amountToPayInWei = 1000000000000000000; // 1 ETH
71+
amountToPayInWei = _amountToPayInWei;
7272
paymentFundsRecipient = _paymentFundsRecipient;
7373
}
7474

0 commit comments

Comments
 (0)