Skip to content

Commit

Permalink
feat(protocol): avoid proving-fee payment if amount is 0 (#16595)
Browse files Browse the repository at this point in the history
  • Loading branch information
dantaik authored Apr 3, 2024
1 parent b019975 commit 761a066
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/protocol/contracts/L1/hooks/AssignmentHook.sol
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ contract AssignmentHook is EssentialContract, IHook {
// Note that this payment may fail if it cost more gas
bool success = _blk.assignedProver.sendEther(proverFee, MAX_GAS_PAYING_PROVER, "");
if (!success) emit EtherPaymentFailed(_blk.assignedProver, MAX_GAS_PAYING_PROVER);
} else {
} else if (proverFee != 0) {
// Paying ERC20 tokens
IERC20(assignment.feeToken).safeTransferFrom(
_meta.sender, _blk.assignedProver, proverFee
Expand Down

0 comments on commit 761a066

Please sign in to comment.