Skip to content

Commit

Permalink
feat(protocol): rename B_BLOCK_PROPOSER to B_PRECONF_REGISTRY (#18255)
Browse files Browse the repository at this point in the history
  • Loading branch information
dantaik authored Oct 16, 2024
1 parent 21c6235 commit bf3caf7
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions packages/protocol/contracts/layer1/based/LibProposing.sol
Original file line number Diff line number Diff line change
Expand Up @@ -150,9 +150,9 @@ library LibProposing {
revert L1_TOO_MANY_BLOCKS();
}

address permittedProposer = _resolver.resolve(LibStrings.B_BLOCK_PROPOSER, true);
if (permittedProposer != address(0)) {
if (permittedProposer != msg.sender) revert L1_INVALID_PROPOSER();
address preconfRegistry = _resolver.resolve(LibStrings.B_PRECONF_REGISTRY, true);
if (preconfRegistry != address(0)) {
if (preconfRegistry != msg.sender) revert L1_INVALID_PROPOSER();
local.allowCustomProposer = true;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ contract RollupAddressCache is AddressCache {
if (_name == LibStrings.B_AUTOMATA_DCAP_ATTESTATION) {
return (true, 0x8d7C954960a36a7596d7eA4945dDf891967ca8A3);
}
if (_name == LibStrings.B_BLOCK_PROPOSER) {
if (_name == LibStrings.B_PRECONF_REGISTRY) {
return (true, address(0));
}
if (_name == LibStrings.B_CHAIN_WATCHDOG) {
Expand Down
2 changes: 1 addition & 1 deletion packages/protocol/contracts/shared/common/LibStrings.sol
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ pragma solidity ^0.8.24;
/// @custom:security-contact security@taiko.xyz
library LibStrings {
bytes32 internal constant B_AUTOMATA_DCAP_ATTESTATION = bytes32("automata_dcap_attestation");
bytes32 internal constant B_BLOCK_PROPOSER = bytes32("block_proposer");
bytes32 internal constant B_BRIDGE = bytes32("bridge");
bytes32 internal constant B_BRIDGE_WATCHDOG = bytes32("bridge_watchdog");
bytes32 internal constant B_BRIDGED_ERC1155 = bytes32("bridged_erc1155");
Expand All @@ -15,6 +14,7 @@ library LibStrings {
bytes32 internal constant B_ERC1155_VAULT = bytes32("erc1155_vault");
bytes32 internal constant B_ERC20_VAULT = bytes32("erc20_vault");
bytes32 internal constant B_ERC721_VAULT = bytes32("erc721_vault");
bytes32 internal constant B_PRECONF_REGISTRY = bytes32("preconf_registry");
bytes32 internal constant B_PROVER_ASSIGNMENT = bytes32("PROVER_ASSIGNMENT");
bytes32 internal constant B_PROVER_SET = bytes32("prover_set");
bytes32 internal constant B_QUOTA_MANAGER = bytes32("quota_manager");
Expand Down

0 comments on commit bf3caf7

Please sign in to comment.