Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix error message #317

Merged
merged 1 commit into from
Sep 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion contracts/v2/consensus/validium/PolygonValidiumEtrog.sol
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ contract PolygonValidiumEtrog is PolygonRollupBaseEtrog, IPolygonValidium {
);

if (l1InfoRoot == bytes32(0)) {
revert L1InfoRootIndexInvalid();
revert L1InfoTreeLeafCountInvalid();
}

// Store storage variables in memory, to save gas, because will be overrided multiple times
Expand Down
4 changes: 2 additions & 2 deletions contracts/v2/interfaces/IPolygonZkEVMVEtrogErrors.sol
Original file line number Diff line number Diff line change
Expand Up @@ -55,9 +55,9 @@ interface IPolygonZkEVMVEtrogErrors is IPolygonZkEVMErrors {
error MaxTimestampSequenceInvalid();

/**
* @dev Thrown when l1 info root does not exist
* @dev Thrown when l1 info tree leafCount does not exist
*/
error L1InfoRootIndexInvalid();
error L1InfoTreeLeafCountInvalid();

/**
* @dev Thrown when the acc input hash does not match the predicted by the sequencer
Expand Down
2 changes: 1 addition & 1 deletion contracts/v2/lib/PolygonRollupBaseEtrog.sol
Original file line number Diff line number Diff line change
Expand Up @@ -442,7 +442,7 @@ abstract contract PolygonRollupBaseEtrog is
);

if (l1InfoRoot == bytes32(0)) {
revert L1InfoRootIndexInvalid();
revert L1InfoTreeLeafCountInvalid();
}

// Store storage variables in memory, to save gas, because will be overrided multiple times
Expand Down
2 changes: 1 addition & 1 deletion test/contractsv2/PolygonZkEVMEtrog.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -490,7 +490,7 @@ describe("PolygonZkEVMEtrog", () => {
expectedAccInputHash,
trustedSequencer.address
)
).to.be.revertedWithCustomError(PolygonZKEVMV2Contract, "L1InfoRootIndexInvalid");
).to.be.revertedWithCustomError(PolygonZKEVMV2Contract, "L1InfoTreeLeafCountInvalid");

await expect(
PolygonZKEVMV2Contract.connect(trustedSequencer).sequenceBatches(
Expand Down
Loading