Skip to content

Commit

Permalink
update 09-King
Browse files Browse the repository at this point in the history
  • Loading branch information
tannerang committed Mar 1, 2024
1 parent 636c678 commit 6a64a61
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/09-KingAttacker.sol
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,10 @@ contract KingAttacker {
(bool success, ) = payable(challengeInstance).call{value: 0.001 ether}("");
require(success, "failed");
}


/**
* This is a non-essential receive function
*/
receive() external payable {
require(msg.sender != challengeInstance, "no more king");
}
Expand Down

0 comments on commit 6a64a61

Please sign in to comment.