Skip to content

Commit

Permalink
fix: use msg.sender instead of userOp.sender
Browse files Browse the repository at this point in the history
  • Loading branch information
kopy-kat committed Apr 4, 2024
1 parent 579ea0b commit ec3760e
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions accounts/safe7579/src/SafeERC7579.sol
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,7 @@ contract SafeERC7579 is
// pay prefund
if (missingAccountFunds != 0) {
_execute({
safe: userOp.getSender(),
safe: msg.sender,
target: entryPoint(),
value: missingAccountFunds,
callData: ""
Expand All @@ -197,7 +197,7 @@ contract SafeERC7579 is
uint48 validUntil,
bytes calldata signatures
) = _getSafeOp(userOp);
try ISafe(payable(userOp.getSender())).checkSignatures(
try ISafe(payable(msg.sender)).checkSignatures(
keccak256(operationData), operationData, signatures
) {
// The timestamps are validated by the entry point,
Expand Down Expand Up @@ -397,7 +397,7 @@ contract SafeERC7579 is
// result of `abi.encode`-ing the individual fields.
EncodedSafeOpStruct memory encodedSafeOp = EncodedSafeOpStruct({
typeHash: SAFE_OP_TYPEHASH,
safe: userOp.sender,
safe: msg.sender,
nonce: userOp.nonce,
initCodeHash: keccak256(userOp.initCode),
callDataHash: keccak256(userOp.callData),
Expand Down

0 comments on commit ec3760e

Please sign in to comment.