@@ -110,6 +110,10 @@ contract Rollup is Leonidas, IRollup, ITestRollup {
110
110
* @dev Will revert if there is nothing to prune or if the chain is not ready to be pruned
111
111
*/
112
112
function prune () external override (IRollup) {
113
+ if (isDevNet) {
114
+ revert Errors.DevNet__NoPruningAllowed ();
115
+ }
116
+
113
117
if (pendingBlockCount == provenBlockCount) {
114
118
revert Errors.Rollup__NothingToPrune ();
115
119
}
@@ -159,7 +163,7 @@ contract Rollup is Leonidas, IRollup, ITestRollup {
159
163
*
160
164
* @param _devNet - Whether or not the contract is in devnet mode
161
165
*/
162
- function setDevNet (bool _devNet ) external override (ITestRollup) {
166
+ function setDevNet (bool _devNet ) external override (ITestRollup) onlyOwner {
163
167
isDevNet = _devNet;
164
168
}
165
169
@@ -170,7 +174,7 @@ contract Rollup is Leonidas, IRollup, ITestRollup {
170
174
*
171
175
* @param _verifier - The new verifier contract
172
176
*/
173
- function setVerifier (address _verifier ) external override (ITestRollup) {
177
+ function setVerifier (address _verifier ) external override (ITestRollup) onlyOwner {
174
178
verifier = IVerifier (_verifier);
175
179
}
176
180
@@ -181,7 +185,7 @@ contract Rollup is Leonidas, IRollup, ITestRollup {
181
185
*
182
186
* @param _vkTreeRoot - The new vkTreeRoot to be used by proofs
183
187
*/
184
- function setVkTreeRoot (bytes32 _vkTreeRoot ) external override (ITestRollup) {
188
+ function setVkTreeRoot (bytes32 _vkTreeRoot ) external override (ITestRollup) onlyOwner {
185
189
vkTreeRoot = _vkTreeRoot;
186
190
}
187
191
0 commit comments