Skip to content

Commit

Permalink
feat(protocol): add GuardianApproval event to GuardianProver (#15817)
Browse files Browse the repository at this point in the history
Co-authored-by: Keszey Dániel <keszeyd@MacBook-Pro.local>
Co-authored-by: Daniel Wang <99078276+dantaik@users.noreply.github.com>
  • Loading branch information
3 people committed Feb 16, 2024
1 parent 665da61 commit 78f0481
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions packages/protocol/contracts/L1/provers/GuardianProver.sol
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,10 @@ import "./Guardians.sol";

/// @title GuardianProver
contract GuardianProver is Guardians {
event GuardianApproval(
address indexed addr, uint256 indexed blockId, bytes32 blockHash, bool approved
);

/// @notice Initializes the contract with the provided address manager.
/// @param _addressManager The address of the address manager contract.
function init(address _addressManager) external initializer {
Expand All @@ -45,5 +49,7 @@ contract GuardianProver is Guardians {
deleteApproval(hash);
ITaikoL1(resolve("taiko", false)).proveBlock(meta.id, abi.encode(meta, tran, proof));
}

emit GuardianApproval(msg.sender, meta.id, tran.blockHash, approved);
}
}

0 comments on commit 78f0481

Please sign in to comment.